jtrovato
08-13-2003, 01:26 AM
I have sessions setup and they worked fine. Then all of a sudden, they stopped working???
<?
session_start();
$_SESSION["var"]='john';
<a href=next.php>next</a>
?>
next.php
[PHP]
<?
session_start();
echo $_SESSION["var"];
?>
Nothing...
What am i doing wrong???
jtrovato
08-13-2003, 01:27 AM
header("Cache-Control: yes-store, yes-cache");
header("Pragma: yes-cache");
will this cause a problem. I have this on the pages so the users don't get an error when they hit the back button
jtrovato
08-13-2003, 01:37 AM
I am calling 2checkout and when I come back i have a different session ID
the 2checkout re-direct routine calls back to a site within the same broswer
is this right?
Rich2k
08-13-2003, 04:45 AM
1st you shouldn't cache session pages as they won't update automatically.
However the PHP you posted is invalid so I can't really tell what isn't working (as I guess you just lifed some parts out of the original script). If you posted more of the code around it we might find the problem.
Try doing a var_dump ($_SESSION);
that will at least tell you if the array is set.
jtrovato
08-13-2003, 10:40 AM
Hey Rich,
I couldn't place the code in the thread so I attached it. I am going to try to dump to see what is stored in the session variables.
Thank you for your time.
Can 2checkout chnage the session variable? It now changes everytime the 2checkout page is called. Where it never did that before.
John