ob_get_contents 获取输出缓存内容

function _require($filename)
{
ob_start();
include $filename;
$content = ob_get_contents();
ob_end_clean();

return $content;
}
include 引入的内容也可以在输入缓存中获取

if (!function_exists('version_compare') || version_compare(phpversion(), '5.3.0', '<')) {
return preg_replace("/{([^}{ ]*)}/e", "$this->select('\1');", $source);
}
php 版本比较函数


原文地址:https://www.cnblogs.com/hehexu/p/9607996.html