2010-06-28 02:05:47 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @file
|
|
|
|
* Miscellaneous functions.
|
|
|
|
*/
|
|
|
|
|
2013-08-21 07:45:23 +00:00
|
|
|
use Drupal\Component\Utility\Variable;
|
|
|
|
|
2010-06-28 02:05:47 +00:00
|
|
|
/**
|
|
|
|
* Drupal-friendly var_export().
|
|
|
|
*
|
2013-07-09 22:51:56 +00:00
|
|
|
* @param mixed $var
|
2010-06-28 02:05:47 +00:00
|
|
|
* The variable to export.
|
2013-07-09 22:51:56 +00:00
|
|
|
* @param string $prefix
|
2011-09-24 20:44:06 +00:00
|
|
|
* A prefix that will be added at the beginning of every lines of the output.
|
2013-01-10 23:50:55 +00:00
|
|
|
*
|
2013-07-09 22:51:56 +00:00
|
|
|
* @return string
|
2010-06-28 02:05:47 +00:00
|
|
|
* The variable exported in a way compatible to Drupal's coding standards.
|
2013-08-21 07:45:23 +00:00
|
|
|
*
|
|
|
|
* @deprecated Use \Drupal\Component\Utility\Variable::export().
|
2010-06-28 02:05:47 +00:00
|
|
|
*/
|
|
|
|
function drupal_var_export($var, $prefix = '') {
|
2013-08-21 07:45:23 +00:00
|
|
|
return Variable::export($var, $prefix);
|
2010-06-28 02:05:47 +00:00
|
|
|
}
|