Session variables don't work!
Posted: Fri May 20, 2005 7:29 am
Hi all,
This aint my first php try, but the following really stuns me:
I have two pages, page1.php and page2.php. I try exchanging variables through SESSION between the two pages.
I can't seem to get the "test" string to get in the page:
So for some reason, php doesn't want to give me a session, although the session_save_path is set, and most (if not all) values in the php.ini are left default.
Am I missing something out here or is my server misconfigured?
Thanks in advance!
This aint my first php try, but the following really stuns me:
I have two pages, page1.php and page2.php. I try exchanging variables through SESSION between the two pages.
Code: Select all
<?php
session_start();
$_SESSIONї"e;test"e;] = "e;test"e;;
?>
<html>
<body>
<a href="e;page2.php"e;>Go forward</a>.
</body>
</html>Code: Select all
<?php
session_start();
echo "e;echoing... "e;;
echo $_SESSIONї"e;test"e;];
?>
<html>
<body>
Test page...
</body>
</html>Code: Select all
echoing... <html>
<body>
Test page...
</body>
</html>Am I missing something out here or is my server misconfigured?
Thanks in advance!