|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2007-04-03 18:58 UTC] tony2001@php.net
[2007-04-04 16:01 UTC] krassesache at gmx dot net
[2007-04-04 16:04 UTC] tony2001@php.net
[2007-04-04 16:24 UTC] krassesache at gmx dot net
[2007-04-04 18:06 UTC] tony2001@php.net
[2007-04-04 18:31 UTC] krassesache at gmx dot net
[2007-04-04 18:46 UTC] tony2001@php.net
[2007-04-05 00:39 UTC] krassesache at gmx dot net
[2007-04-05 00:56 UTC] scottmac@php.net
[2007-04-05 10:12 UTC] krassesache at gmx dot net
[2007-04-05 10:21 UTC] krassesache at gmx dot net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Dec 03 09:00:01 2025 UTC |
Description: ------------ if i use $_SERVER in any way but with pdo statements [ $stmt->execute(array($_SERVER['REMOTE_ADDR'])) ] a session will not work. in my example i first open foobar.php and then foobar2.php. if remove the 4th line in foobar2.php [ $var = $_SERVER['REMOTE_ADDR']; ] the the text "bar" appears but with the line, nothing happens. in other case is used preg_match('#MSIE#',$_SERVER['HTTP_USER_AGENT']) with the result that the website will be shown but the session dont work (the original problem). Reproduce code: --------------- => foobar.php <?php session_start(); $_SESSION['foo'] = 'bar'; ?> => foobar2.php <?php session_start(); $var = $_SERVER['REMOTE_ADDR']; echo $_SESSION['foo']; ?> Expected result: ---------------- bar Actual result: -------------- <nothing>