I'm having a problem with cookies and php
"This is out of a book"
my first page is:
<?
session_start();
$sess_var = "Hello world!";
session_register("sess_var");
echo "The content of \$sess_var is $sess_var<br>";
echo "<br>" ;
print_r ($_SESSION);
echo "<br>" ;
print_r ($_COOKIE);
echo "<br>" ;
?>
<br>
<a href = "page2.php">Next page</a>
my page2 is:
<?
session_start();
echo "<br>" ;
print_r ($_SESSION);
echo "<br>" ;
print_r ($_COOKIE);
echo "<br>" ;
echo "The content of \$sess_var is $sess_var" ;
echo "<br>" ;
//session_unregister("sess_var");
?>
<a href = "page3.php">Next page</a>
the problem is that it will not carry the value to the next page ??????
I think it's a setup problem, because it does not create a cookie on the browsing machine...
tia
"Hacker by Heart"
saenzcorp@hotpop.com
"This is out of a book"
my first page is:
<?
session_start();
$sess_var = "Hello world!";
session_register("sess_var");
echo "The content of \$sess_var is $sess_var<br>";
echo "<br>" ;
print_r ($_SESSION);
echo "<br>" ;
print_r ($_COOKIE);
echo "<br>" ;
?>
<br>
<a href = "page2.php">Next page</a>
my page2 is:
<?
session_start();
echo "<br>" ;
print_r ($_SESSION);
echo "<br>" ;
print_r ($_COOKIE);
echo "<br>" ;
echo "The content of \$sess_var is $sess_var" ;
echo "<br>" ;
//session_unregister("sess_var");
?>
<a href = "page3.php">Next page</a>
the problem is that it will not carry the value to the next page ??????
I think it's a setup problem, because it does not create a cookie on the browsing machine...
tia
"Hacker by Heart"
saenzcorp@hotpop.com