Session variables in files that have been "required".

From: Date: Mon, 06 Nov 2000 10:39:38 +0000
Subject: Session variables in files that have been "required".
Groups: php.general 
Request: Send a blank email to php-general+get-23867@lists.php.net to get a copy of this message
I have various session variable registered, but tnone of them seem to work in files that have been included in the page with the "require" construct. For example, I have a function that takes an ID number ($IDa), and in that function $IDa gets compared to a sessions variable $own_id. I know that $own_id is set correctly in a previous page, because in this instance it is $own_id being passed to the function, and I can do
        echo $IDa." = ".$own_id;
and see
        1 =
I can't access $own_id either directly, or via $HTTP_SESSION_VARS. I also see the same behavior if I use INCLUDE. I'm using PHP4.0.3pl1 on Debian 2.2 potato. Installed from the Debian packages available from the Debian site.
                                    ,,,
                                   (o o)
===============================oOO==(_)==OOo==================================
Stuart Grimshaw                                             sg@schoolsnet.com
Special Projects Developer   www.schoolsnet.com               t: 07976 625221
Schoolsnet LTD                 .oooO  Oooo.                   f: 0870 7060260
===============================( )==( )===================================
                                \ (    ) /
                                 \_)  (_/


« previous php.general (#23867) next »