Thinkphp 关闭Gzip header输出问题
Thinkphp默认开启gzip压缩
'OUTPUT_ENCODE' => true, // 页面压缩输出
<br /> // 页面压缩输出支持<br /> if(C('OUTPUT_ENCODE')){<br /> $zlib = ini_get('zlib.output_compression');<br /> if(empty($zlib)) ob_start('ob_gzhandler');<br /> }<br />
<br /> if(C('OUTPUT_ENCODE')){<br /> ob_flush();<br /> ob_clean();<br /> }<br /> <br /> $thumburi = 'Thumb/666.jpg';<br /> $type = getimagesize($thumburi);<br /> header("Content-type: ". $type['mime']);<br /> readfile($thumburi);<br /> die();<br />