Hello dear friends,
I have a script creating a session on one page. When i move to another page, i used to echo an unordered list after checking that a session variable exists.
Now, that is not only impossible on my PC but also impossible on the hosting server. I cant figure out whats wrong at all
This is how the script looks like:
session_start();
echo '<ul><li><a
href="annonce_definitive.php">Retour aux
annonces</a></li>';
if(isset($_SESSION['user']))
{
if($_SESSION['user'] ==
'dbarasuk')
{
echo "<li><a
href='confirmer_suppression.php?immo_id=".$immo_
id."'>Supprimer cette annonce</a></li>
<li><a
href='annonce_definitive_modifier.php?immo_id=".
$immo_id."'>Modifier cette annonce</a></li>
<li><a
href=logout.php>Log out</a></li>";
}
}
echo "</ul>";
}
The $_SESSION['user'] key is previously created on a login page
The problem is that everything inside the if control structure is totally ignored, but i know that it evaluates to 'TRUE' because if i echo the session key at the very beginning of the page, it echoes faultlessy the value.
Can someone help me please?