If I understand the idea behind session variables correctly, the following should work, but it does not. My understanding of session variables is that during a brouser session you execute a php script (in this case t1.php), and before ending the brouser session, execute another php script (in this case t2.php), the variables defined as "session variables" should still be active in the second script called.
The code below works FINE...if the user TAKES the cookie generated when start_session is called in t1.php. HOWEVER, if you do NOT take the cookie, when you execute t2.php the $_session['fp_user'] variable is blank.
In any event here is my test code that does not work when you do not accept the cookie.
Any ideas or at least explainations as to what is going wrong or how to get around this problem. In my real code my process is obviously more complex than this sample code, however the principal problem is the same... I need info from one script for another. The reason that this is a problem is that I am trying to anticipate that the user might have "do not accept cookies" set in his brouser, and I am trying to work around this issue.
t1.php:
<?php
session_start();
$SESSION['fp_user'] = "testValue111";
$msg = "T1 = " . $SESSION['fp_user'];
echo "<SCRIPT>alert(\"$msg\")</SCRIPT>";
?>
t2.php:
<?php
session_start();
$msg = "T2 Value = " . $_SESSION['fp_user'];
echo "<SCRIPT>alert(\"$msg\")</SCRIPT>";
?>