I'm not sure if this is related (possibly), but I has similar problems with
I doiscovered that the cookie was only being set if the page that set it
actually produced HTML. By redirecting, you cut out the HTML-writing.
Why not redirect the user if the test fails instead.
> -----Original Message-----
> From: Lars Rasmussen [mailto:[EMAIL PROTECTED]
> Sent: 12 March 2003 3:40 pm
> To: [EMAIL PROTECTED]
> Subject: [PHP-DB] session and header("location....")
> Hi everyone,
> Thanks for looking at my question!
> Well, i just made a script that firstly check's up username and password
> (log-in script) then next if the user enteret the correct information a
> session is set like this:
> $_SESSION['ngskdsngjkla465gfdh'] = "LOGETIN-TRUE";
> But then when this session is set it changes from the log in page to the
> real password-protected page.
> I tried with a normal header location, but it did'nt work, so i tried to
> look at php.net about sessions, it says that you're had to transfer the
> sessionid to the next page. Now i'm trying that, but it just wount
> The header location im using looks like this:
> And i also tried with:
> But none of them will work....i hope you will look at it, and tell me if
> you have a solution.
> Thanks folks.
> Lars Rasmussen
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php