_drupal_rewrite_settings_dump_one(\stdClass $variable, $prefix = '', $suffix = '')
Helper for drupal_rewrite_settings().
Dump the value of a value property and adds the comment if it exists.
object $variable: A stdClass object with at least a value property.
string $prefix: A string to prepend to the variable's value.
string $suffix: A string to append to the variable's value.
string A string containing valid PHP code of the variable suitable for placing into settings.php.
function _drupal_rewrite_settings_dump_one(\stdClass $variable, $prefix = '', $suffix = '') { $return = $prefix . var_export($variable->value, TRUE) . ';'; if (!empty($variable->comment)) { $return .= ' // ' . $variable->comment; } $return .= $suffix; return $return; }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!includes!install.inc/function/_drupal_rewrite_settings_dump_one/8.1.x