Thread: session php
View Single Post
  #2 (permalink)  
Old Apr 6th, 2004, 08:54
Webforumz Staff Webforumz Staff is offline
Most Reputable Member
Join Date: Jul 2003
Posts: 1,856
Thanks: 0
Thanked 0 Times in 0 Posts
Sessions use cookies.

You can't have a single line printed to the client otherwise, the headers are sent. You can't send the headers twice.

Cookies must be sent before ANYTHING else in the page because they go in the header. Thus this code will only work if it's the first thing in your document.