#25387 [Com]: session_start() always creates new session
| From: | phpfrost at frost-web dot de | Date: | Tue, 27 Apr 2004 05:25:28 +0000 |
| Subject: | #25387 [Com]: session_start() always creates new session | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-58845@lists.php.net to get a copy of this message | ||
ID: 25387
Comment by: phpfrost at frost-web dot de
Reported By: alex at rapidfans dot at
Status: Bogus
Bug Type: Session related
Operating System: windows xp
PHP Version: 4.3.3
New Comment:
I reconsturuated the problem with the Session_id.
I found out that "session_start" generates a new session_id every time,
if the session.cookie_path-parameter in the php.ini is not set up
right.
Look at your php.ini-File. If the session_cookie_path-parameter is set
up to session.cookie_path = / , all things are right. If there is
another value than '/', this could be the reason for the problem.
Mathias
Previous Comments:
------------------------------------------------------------------------
[2003-09-03 16:58:00] sniper@php.net
Sorry, but your problem does not imply a bug in PHP itself. For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system
is not the
appropriate forum for asking support questions.
Thank you for your interest in PHP.
..
------------------------------------------------------------------------
[2003-09-03 16:38:20] alex at rapidfans dot at
Description:
------------
im using php 4.3.3, system xp, apache 1.3
globals off,
first page:
session_start();
$_SESSION["test"] = "ok";
second page:
session_start();
echo($_SESSION["test"]);
but on the second page, the session is created new.
(my browser accepts cookies)
whats wrong?
Reproduce code:
---------------
session_start();
$_SESSION["test"] = "ok";
session_start();
echo($_SESSION["test"]);
Actual result:
--------------
nothing in session
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=25387&edit=1