I have a problem with session as:
if i write :
<?php
$_SESSION['id'] = 4;
$id = 7;
print $_SESSION['id']; // result: 4
?>
varible of $_SESSION['id'] is 4, but i write :
a.php
<?php
session_start() ;
$_SESSION['a'] = 4;
$a = 5;
echo '<a href="b.php">b. php</a>';
?>
b.php
<?php
session_start() ;
print $_SESSION['a']; // result: 5
?>
i use Apache 2.2.8, PHP 5.2.6 ( embed in AppServ 2.5.10)
help me!
if i write :
<?php
$_SESSION['id'] = 4;
$id = 7;
print $_SESSION['id']; // result: 4
?>
varible of $_SESSION['id'] is 4, but i write :
a.php
<?php
session_start() ;
$_SESSION['a'] = 4;
$a = 5;
echo '<a href="b.php">b. php</a>';
?>
b.php
<?php
session_start() ;
print $_SESSION['a']; // result: 5
?>
i use Apache 2.2.8, PHP 5.2.6 ( embed in AppServ 2.5.10)
help me!
Comment