Page 1 of 1

Sessions not working across pages...

Posted: Mon Dec 29, 2008 2:23 pm
by yoji
I have tried everything... Lmme show you the code first:
This is page 1:

Code: Select all

 
<?php
session_start();
$_SESSION['name']='dexter';
echo $_SESSION['name'];
?>
<a href="page.php">Go to this page</a>
 
This is page.php:

Code: Select all

 
<?php
session_start();
echo $_SESSION['name'];
?>
 
Session works just fine for that one page.. Where it echoes. But on the second page it gives this error:Undefined variable: _SESSION.
I have tried everything.. I have been through documentation. I have just finished comparing my php.ini sessions part with the online defaults.. I have been through documentation. I have even changed my php version because I though the prob might be a bug or something in my version... Nothing Is Working... Kindly help me out here...

Re: Sessions not working across pages...

Posted: Mon Dec 29, 2008 2:35 pm
by jaoudestudios
Reposting the same question again and again will not get someone to help you faster.