View Single Post
  #2 (permalink)  
Old 09-03-2008, 11:36 PM
John's Avatar   
John John is offline
Co-Administrator
 
Join Date: Jul 2006
Age: 20
Posts: 3,569
Last Blog:
Tidy up your HTML
Credits: 0
Rep Power: 20
John has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond reputeJohn has a reputation beyond repute
Send a message via AIM to John Send a message via MSN to John
Default Re: Question on Sessions

Quote:
Originally Posted by shiyam198 View Post
When I did that, I got the following error message.
(output started at top.htm............"

I took the code segment out from all the pages and put on top of top.php, it works fine.

Why does that session_start() should be on top the file. Or is it some other problem caused this error ?
The cache limiter warning is issued when content is outputted prior to the session_start() directive being called. That said, it must be placed at the top of the page (or before you output any content). I'm not sure the reasoning behind it - I just accepted it.
Reply With Quote