Re: Session vars not echoing?

From: Date: Thu, 20 Nov 2003 17:36:16 +0000
Subject: Re: Session vars not echoing?
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-170451@lists.php.net to get a copy of this message
Yeah I did that, sorry I just didn't note it in the snippit.. and it is now working with the $_SESSION function, i just had to restart the browser to clear the cache after updating the code. jas Pete M wrote:
need to issue a session_start() at top of page Pete Jas wrote:
Not sure why this is happening but I think it has something to do with an include statement... [Server environment] Apache/2.0.47 (Unix) DAV/2 PHP/4.3.3
register_globals    On    On
report_memleaks    On    On
safe_mode    Off    Off
safe_mode_exec_dir    no value    no value
Session Support     enabled
[Script registering vars - sessions.php] /* Format Date & Time */ $hour = (date("H:i:s")); $day = (date("d")); $date = (date("F $day, Y")); /* Register vars */ $_SESSION['date'] = $date; [Main script - index.php]
session_start()
require 'scripts/sessions.php'; echo $_SESSION['date']; //This is not showing up in browser? Any help is appreciated... Jas


« previous php.general (#170451) next »