#21416 [Com]: Session variables timeout prematurely
| From: | maladil at everstkc dot net | Date: | Sat, 04 Jan 2003 20:54:46 +0000 |
| Subject: | #21416 [Com]: Session variables timeout prematurely | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-29064@lists.php.net to get a copy of this message | ||
ID: 21416
Comment by: maladil@everstkc.net
Reported By: maladil@everstkc.net
Status: Feedback
Bug Type: Session related
Operating System: Redhat 7.3
PHP Version: 4.2.1
New Comment:
I suggest copying the link into your browser to check this out. I
clicked on the link from the ticket and the $_SESSION variable won't
appear on any page but one.php, however if you copy the link into the
browser then you can still see the variable for about 45 seconds until
it seems to time out.
Thanks,
Jason
Previous Comments:
------------------------------------------------------------------------
[2003-01-04 14:50:52] nicos@php.net
Please try using this CVS snapshot:
http://snaps.php.net/php4-latest.tar.gz
For Windows:
http://snaps.php.net/win32/php4-win32-latest.zip
------------------------------------------------------------------------
[2003-01-04 14:44:29] maladil@everstkc.net
I am having problems getting simple $_SESSION[] variable to go from one
page to the next. I have created an extremely stripped down version of
the rest of my code and it can be reached at
http://gcfc.net/testsite1/docs/misc/one.php
our php and server settings are here....
http://gcfc.net/testsite1/debug.php
Simply put, one.php sets a session variable. two.php and three.php
simply check to see if that session variable is set. If you go from
one.php to two.php and wait for 60 seconds then the session variable is
no longer present, but the session id is still intact. This happens on
IE and Netscape.
I have included my code below for the first 2
pages...........................
<?php
//one.php
session_start();
$_SESSION['person']="Bob";
?>
<html><head><title>Session Test page 1</title></head>
<body>
<h1>You are at page 1</h1>
<br>
<a href="two.php">Page 2</a><br>
<a href="three.php">Page 3</a>
<br>Session variable person is
<?php echo $_SESSION['person']; ?>
<br>Session ID = <?php echo session_id(); ?>
</body>
</html>
********************************
<?php session_start(); ?>
<html><head><title>Session Test page 2</title></head><body>
<h1>You are at page 2</h1><br>
<a href="one.php">Page 1</a><br>
<a href="three.php">Page 3</a><br>
<a href="four.php">Page 4, briefly</a>
<br>Session variable person is
<?php echo $_SESSION['person']; ?>
<br>Session ID = <?php echo session_id(); ?>
</body>
</html>
****************************************
Thanks
Jason
maladil@everestkc.net
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=21416&edit=1