PHP session_start()错误? [英] PHP session_start() error?
本文介绍了PHP session_start()错误?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
可能重复:
已发送PHP标头
Possible Duplicate:
PHP headers already sent
所以我刚加入Hostgator.com,想知道为什么我总是会收到此错误:
So I just joined Hostgator.com, and was wondering, why do I always get this error:
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /home/kapip/public_html/main/mainpage.php:5) in /home/kapip/public_html/main/mainpage.php on line 7
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/kapip/public_html/main/mainpage.php:5) in /home/kapip/public_html/main/mainpage.php on line 7
这是什么意思?我知道我可能必须编辑php.ini,但是我不确定要更改什么.谁能帮我吗?谢谢!
What does this mean? I know I have to probably edit the php.ini, but I'm not sure what to change. Can anyone help me out? Thank you!
推荐答案
在执行session_start()
例如
// whitespace, any mark up or include that displays something <HERE>
// it will give you that error
<?php
session_start();
这篇关于PHP session_start()错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文