Page 1 of 1

PHP Header already sent error on UNIX/Apache but not Win/IIS

Posted: Mon Jan 29, 2007 3:11 am
by josefv
I'm using PHP 5.2.0 on two separate machines. When I work on my site using machine A (Windows with IIS), which works perfectly with my site, hosted locally for testing at home.

When I copy my site to our UNIX server at work, which of course uses Apache, I get errors indicating that headers have already been sent, and the error points to the start_session() function called.

Is there a setting in php.ini or something that is different in the two setups?

Posted: Mon Jan 29, 2007 3:57 am
by dibyendrah
The problem is due to sending the output to the browser and using header function. Trace the statement which is sending output to the browser before header and your problem is solved.

And regarding the configuration, yes they differs from each other.