note 22240 added to ref.session

From: Date: Wed, 12 Jun 2002 00:31:22 +0000
Subject: note 22240 added to ref.session
Groups: php.notes 
Request: Send a blank email to php-notes+get-31715@lists.php.net to get a copy of this message
If you only want to use cookies to preserve the session and don't want to send a header(location:URL) with the sessiond id, make sure that the session_start() is called on any page before the header(location: ) is sent. That's because if the session_start() is called for the first time at the same time as the header(location: ) the cookie is not set by the browser. After the cookie is already set on a page without the redirect, you can use header(location:)'s all you want. -- http://www.php.net/manual/en/ref.session.php http://master.php.net/manage/user-notes.php?action=edit+22240 http://master.php.net/manage/user-notes.php?action=delete+22240 http://master.php.net/manage/user-notes.php?action=reject+22240

« previous php.notes (#31715) next »