#44320 [Bgs]: Sessions aren't restarting or renewing
ID: 44320
Updated by: jani@php.net
Reported By: tidus_david at hotmail dot com
Status: Bogus
Bug Type: Session related
Operating System: Windows Vista
PHP Version: 5.2.5
New Comment:
I'd check that config.php file for whitespace before <?php tag..:)
Previous Comments:
------------------------------------------------------------------------
[2008-03-05 09:19:30] jani@php.net
Nothing has changed in this regard, you just have done a mistake in
your script. NOTHING can be output before calling session_start().
------------------------------------------------------------------------
[2008-03-04 05:37:11] tidus_david at hotmail dot com
Description:
------------
In the new version of php, the sessions seems to be bad because they
say that headers are already sent... so it is not updating the cookie
thing, better explanation with the code, by the way, my page is
http://dfun.servegame.com/minimanager so you can
see what happens
Reproduce code:
---------------
//set user variables
session_regenerate_id();
$user_lvl = $_SESSION['user_lvl'];
$user_name = $_SESSION['uname'];
$user_id = $_SESSION['user_id'];
$realm_id = (isset($_GET['r_id'])) ? addslashes($_GET['r_id']) :
$_SESSION['realm_id'];
Expected result:
----------------
It should load the menus correctly and show a tooltip when you put the
mouse over the any menu, but it loads bad
Actual result:
--------------
session_regenerate_id() [function.session-regenerate-id]: Cannot
regenerate session id - headers already sent in
C:\server\htdocs\Minimanager\header.php on line 73
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=44320&edit=1
Thread (4 messages)