thinkphp的模版引擎,把渲染结果返回到变量中,而不直接输出到浏览器.
想用来整理渲染html转PDF
public function index()
{
ob_start();//打开缓冲区输出
$html = View::fetch();
ob_end_flush();
return $html . "OK";
}
原理是在要输出浏览器的部分使用ob清除掉。
thinkphp的模版引擎,把渲染结果返回到变量中,而不直接输出到浏览器.
想用来整理渲染html转PDF
public function index()
{
ob_start();//打开缓冲区输出
$html = View::fetch();
ob_end_flush();
return $html . "OK";
}
原理是在要输出浏览器的部分使用ob清除掉。
要发表评论,您必须先登录。