function dump($vars, $label = '', $return = false) {
if (ini_get('html_errors')) {
$content = "<pre class="brush:php;toolbar:false;">\n";
if ($label != '') {
$content .= "<strong>{$label} :</strong>\n";
}
$content .= htmlspecialchars(print_r($vars, true));
$content .= "\n\n";
} else {
$content = $label . " :\n" . print_r($vars, true);
}
if ($return) { return $content; }
echo $content;
return null;
}
参考:
http://www.birdol.com/web/751.html
Perl 基础教程 chm下载Perl 基础入门中文教程,chm格式,讲述PERL概述、简单变量、操作符、列表和数组变量、文件读写、模式匹配、控制结构、子程序、关联数组/哈希表、格式化输出、文件系统、引用、面向对象、包和模块等知识点。适合初学者阅读和了解Perl脚本语言。
以上就介绍了工具|PHP格式化输出数组,包括了方面的内容,希望对PHP教程有兴趣的朋友有所帮助。










