View Single Post
  #105  
Old 17th October 2008, 22:58
johnake's Avatar
johnake johnake is offline
Senior Member
 
Join Date: Dec 2007
Posts: 52
Default
Quote:
Originally Posted by TheArcadeMaster View Post
i installed the forum and all went will exept now i have these errors or warnings

Code:
Warning: Cannot modify header information - headers already sent by (output started at /home/arcadega/public_html/master/themes/ICGstation/stdhead.php:65) in /home/arcadega/public_html/master/phpBB2/includes/sessions.php on line 377

Warning: Cannot modify header information - headers already sent by (output started at /home/arcadega/public_html/master/themes/ICGstation/stdhead.php:65) in /home/arcadega/public_html/master/phpBB2/includes/sessions.php on line 378

Warning: Cannot modify header information - headers already sent by (output started at /home/arcadega/public_html/master/themes/ICGstation/stdhead.php:65) in /home/arcadega/public_html/master/phpBB2/includes/page_header.php on line 488

Warning: Cannot modify header information - headers already sent by (output started at /home/arcadega/public_html/master/themes/ICGstation/stdhead.php:65) in /home/arcadega/public_html/master/phpBB2/includes/page_header.php on line 494

Warning: Cannot modify header information - headers already sent by (output started at /home/arcadega/public_html/master/themes/ICGstation/stdhead.php:65) in /home/arcadega/public_html/master/phpBB2/includes/page_header.php on line 495
anybody know how to fix this plz help
On a production server, it is always recommended that you have the following settings in php.ini:
Code:
log_errors On
display_errors Off
error_log path/to/error/directory
This disables the output of warnings and php error messages and logs them into a file.

As for debugging the problem in cause:
1) Find the header() statement that is causing the problem. The error must be at or before this line.

2) Look for any statements that could send output to the user before this header statement. If you find one or more, find some way to move the header statement before them. Complex conditional statements may complicate the issue, but they may also help solve the problem. Consider a conditional expression at the top of the PHP script that determines the header value as early as possible and sets it there.


3) Make sure there is no white space outside of the php start and end tags. While a blank line before the start tag may look innocent, when processed by PHP, it will turn into an echo statement printing out a blank line. This is a common mistake.


__________________
PHP Code:
class mySelf extends World
   
{
       public 
$health;
       private 
$friends;
       protected 
$love;
  
   public function 
__construct()
  {
       
$this->health 100;
       
$this->friends 2;
       
$this->love true;
  }
  protected function 
__love()
  { 
      
//has a bug... for the moment...
      //will fix it later.. until then:
      
sleep(15*365*24*3600);
  }

Reply With Quote