Return to Snippet

Revision: 51553
at September 28, 2011 04:32 by iloveitaly


Initial Code
function format_php_export($arrayRep) {
	$arrayRep = preg_replace('/[ ]{2}/', "\t", $arrayRep);
	$arrayRep = preg_replace("/\=\>[ \n\t]+array[ ]+\(/", '=> array(', $arrayRep);
	return $arrayRep = preg_replace("/\n/", "\n\t", $arrayRep);
}

Initial URL

                                

Initial Description
Format's var export so things looks a little bit nicer

Initial Title
Format PHP Var Export

Initial Tags
php

Initial Language
PHP