ecshop显示Warning: Cannot modify header information

作者: admin 分类: ecshop 发布时间: 2012-08-23 07:10

今天郴州做网站在本地假设一个本地服务器,什么都配置好后,打开网站显示:
Warning: Cannot modify header information – headers already sent by (output started at D:\amp\www\htdocs\data\config.php:1) in D:\amp\www\htdocs\includes\cls_session.php on line 116
Warning: Cannot modify header information – headers already sent by (output started at D:\amp\www\htdocs\data\config.php:1) in D:\amp\www\htdocs\includes\cls_template.php on line 58
开始以为是修了CONFIG.php配置文件造成的,但是发现文件是UFT8格式的,没有问题,后来发现是缓存的问题:
打开php.ini,把output_buffering默认的Off设为4096就OK了,这个值可以设置成On,但这里设置成数值,能解决问题.
修改完PHP.ini配置文件后,一定要重启服务器才能生效。