Warning: session_start() [function.session-start]: Cann.....

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
prue_
Forum Commoner
Posts: 64
Joined: Thu May 07, 2009 10:34 pm

Warning: session_start() [function.session-start]: Cann.....

Post by prue_ »

hi, can someone help me with this? I keep getting this error....

Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by ......

I tried to upload my files to other servers but the error doesn't show.. why am I getting this error when I upload it to this specific server?

thanks a lot.
Naeem
Forum Commoner
Posts: 31
Joined: Tue Jul 07, 2009 12:48 pm

Re: Warning: session_start() [function.session-start]: Cann.....

Post by Naeem »

can you please post your code OR try this one
Put your code between this function where you are using session and header

Code: Select all

ob_start();
Your code
ob_end_flush();
prue_
Forum Commoner
Posts: 64
Joined: Thu May 07, 2009 10:34 pm

Re: Warning: session_start() [function.session-start]: Cann.....

Post by prue_ »

thanks, it solved the problem.. :)
Post Reply