note 96807 added to session.idpassing

From: Date: Wed, 17 Mar 2010 06:23:32 +0000
Subject: note 96807 added to session.idpassing
Groups: php.notes 
Request: Send a blank email to php-notes+get-167122@lists.php.net to get a copy of this message
The first time a page is accessed, PHP doesn't yet know if the browser is accepting cookies or not, so after session_start() is called, SID will be non-empty, and the PHPSESSID gets inserted in all link URLs on that page that are properly using SID. This has the consequence that if, for example, a search engine bot hits your home page first, all links that it sees on your home page will have the ugly PHPSESSID=... in them. This appears to be the default behavior. A work-around is to turn on session.use_only_cookies, but then you lose session data for anyone who has their cookies turned off. ---- Server IP: 69.147.83.197 Probable Submitter: 24.4.180.243 ---- Manual Page -- http://www.php.net/manual/en/session.idpassing.php Edit -- https://master.php.net/note/edit/96807 Del: integrated -- https://master.php.net/note/delete/96807/integrated Del: useless -- https://master.php.net/note/delete/96807/useless Del: bad code -- https://master.php.net/note/delete/96807/bad+code Del: spam -- https://master.php.net/note/delete/96807/spam Del: non-english -- https://master.php.net/note/delete/96807/non-english Del: in docs -- https://master.php.net/note/delete/96807/in+docs Del: other reasons-- https://master.php.net/note/delete/96807 Reject -- https://master.php.net/note/reject/96807 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#167122) next »