1 頁 (共 1 頁)

[問題]PHP首頁打開出現錯誤訊息,請各位大大幫忙.....

發表於 : 2004-09-05 18:54
紅酒加乳酪
OS種類版本:Linux
MySQL版本:4.0.18
Apache版本:1.3.29 (Unix)
PHP版本:4.3.4
phpBB版本:phpBB-2.0.10 +subSilver+繁中語言
架在虛擬主機上
各位大大您好;
小弟剛看完[教學] 如何讓你的網站在搜尋引擎上找到這篇文章後 http://phpbb-tw.net/phpbb/viewtopic.php?t=22713 ,然後按照裡面的方法修改,結果首頁上就出現以下錯誤訊息;
Warning: Cannot modify header information - headers already sent by (output started at /home/jacklo/public_html/phpBB2/includes/functions.php:847) in /home/jacklo/public_html/phpBB2/includes/sessions.php on line 188

代碼: 選擇全部

setcookie($cookiename . '_data', serialize($sessiondata), $current_time + 31536000, $cookiepath, $cookiedomain, $cookiesecure);
Warning: Cannot modify header information - headers already sent by (output started at /home/jacklo/public_html/phpBB2/includes/functions.php:847) in /home/jacklo/public_html/phpBB2/includes/sessions.php on line 189

代碼: 選擇全部

setcookie($cookiename . '_sid', $session_id, 0, $cookiepath, $cookiedomain, $cookiesecure);
Warning: Cannot modify header information - headers already sent by (output started at /home/jacklo/public_html/phpBB2/includes/functions.php:847) in /home/jacklo/public_html/phpBB2/includes/page_header.php on line 475

代碼: 選擇全部

header ('Cache-Control: private, pre-check=0, post-check=0, max-age=0');
Warning: Cannot modify header information - headers already sent by (output started at /home/jacklo/public_html/phpBB2/includes/functions.php:847) in /home/jacklo/public_html/phpBB2/includes/page_header.php on line 477

代碼: 選擇全部

header ('Expires: 0');
Warning: Cannot modify header information - headers already sent by (output started at /home/jacklo/public_html/phpBB2/includes/functions.php:847) in /home/jacklo/public_html/phpBB2/includes/page_header.php on line 478

代碼: 選擇全部

header ('Pragma: no-cache');
請問各位大大小弟是否有地方遺漏了還是設定有錯誤呢?
麻煩各位大大抽空幫小弟解答,感激不盡!!!

發表於 : 2004-09-06 00:08
messagebox
output started at /home/jacklo/public_html/phpBB2/includes/functions.php:847
這個錯誤訊息重點在這段文字~~~

意思是說~標準輸出已經在這檔案的847行做過了~~
所以你後面送檔頭都會出錯~

所謂檔頭~就是你貼出來再code的那些~~~
我想~你的functions.php並非是以?>作檔案結尾的吧\r

換行字元~空白字元都算送出標準輸出~~