#19068 [Opn->Csd]: $_SESSION behaves like session_register(), but doesn't call session_start()

From: Date: Sat, 18 Jan 2003 05:53:06 +0000
Subject: #19068 [Opn->Csd]: $_SESSION behaves like session_register(), but doesn't call session_start()
References: 1  Groups: php.doc 
Request: Send a blank email to phpdoc+get-969350973@lists.php.net to get a copy of this message
ID: 19068 Updated by: philip@php.net Reported By: mfischer@php.net -Status: Open +Status: Closed Bug Type: Documentation problem Operating System: Any PHP Version: 4CVS-2002-08-23 New Comment: This has now been documented: http://cvs.php.net/cvs.php/phpdoc/en/reference/session/functions/session-register.xml http://cvs.php.net/cvs.php/phpdoc/en/reference/session/reference.xml Thanks for the report :) Previous Comments: ------------------------------------------------------------------------ [2002-08-23 08:12:00] mfischer@php.net Damn, doc problem of course. ------------------------------------------------------------------------ [2002-08-23 08:10:38] mfischer@php.net The manual page about session_register (http://www.php.net/manual/en/function.session-register.php) says: "Caution: If you are using $_SESSION (or $HTTP_SESSION_VARS), do not use session_register(), session_is_registered() and session_unregister()." and a few lines later "If session_start() was not called before this function is called, an implicit call to session_start() with no parameters will be made." But the latter is not true if only $_SESSION is used to register a session variable. The current implementation requires a manual call to session_start(). This should be noted there. Idially, it should be mentioned also at http://www.php.net/manual/en/ref.session.php (where it says: Note: As of PHP 4.1.0, $_SESSION is available as global variable just like ...) and maybe also at http://www.php.net/manual/en//language.variables.predefined.php (which may be too much good will though ;) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=19068&edit=1

« previous php.doc (#969350973) next »