Sessions: Wath's my mistake??
| From: | Tom�s Liendo | Date: | Sat, 17 May 2003 06:18:15 +0000 |
| Subject: | Sessions: Wath's my mistake?? | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-148007@lists.php.net to get a copy of this message | ||
I did all your town councils, but my athentification system doesn't work.
Here are my scripts:
if(mysql_num_rows($result)!=0)
{
session_start();
//global $HTTP_SESSION_VARS; (it doesn't
influence in anything)
$HTTP_SESSION_VARS['authentified']="YES";
header("Location: page1.php");
...
And in the other file (page1.php):
session_start();
//global $HTTP_SESSION_VARS; (it doesn't influence in anything)
if($HTTP_SESSION_VARS['autthentified']!="YES")
{
echo "Error.<br>";
}
else
{
...
I always receipt the Error message. I think that it is because the second
script takes $HTTP_SESSION_VARS as a new variable and not as a session
variable.
Help me pleaseeeeeeee!
Ahead of time, thank you very much,
Tom.