[PHP] PHP header command crashes IE6x/PC

2003-12-12 Thread Matt MacLeod
Hi,

I have written a login system in PHP which appears to work OK except on 
a particular windows network. Basically the user can log in, but after 
viewing a few pages IE crashes.

I can view the same site on my PowerBook using Safari with no problems.

The offending code is as follows:

?php
session_start();
if (!ISSET($_SESSION['loggedin'])) {
header(Location: /admin/login/);
}
else
{
//rest of the page.
}
?
Any ideas why this would cause IE to crash

Cheers,

Matt

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] PHP header command crashes IE6x/PC

2003-12-12 Thread CPT John W. Holmes
From: Matt MacLeod [EMAIL PROTECTED]

 if (!ISSET($_SESSION['loggedin'])) {
 header(Location: /admin/login/);

put exit(); after your header redirect and use a full URL for your location.

---John Holmes...

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] PHP header command crashes IE6x/PC

2003-12-12 Thread Matt MacLeod
John,

Have tried this but unfortunately had no effect.

Everything appears to fine if the session variable does not exist ie: 
the user is redirected to the log in page.

It's just when the user has logged in and the session is set that IE 
throws it's toys out of the pram.

Cheers,
Matt
On Friday, December 12, 2003, at 03:15 PM, CPT John W. Holmes wrote:

From: Matt MacLeod [EMAIL PROTECTED]

if (!ISSET($_SESSION['loggedin'])) {
header(Location: /admin/login/);
put exit(); after your header redirect and use a full URL for your 
location.

---John Holmes...

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] PHP header command crashes IE6x/PC

2003-12-12 Thread Cesar Cordovez
Somebody, IIRC, told the list that the argument for header(Location... 
has to be a complete url, not just a directory, ie:

header(Location: http://www.alenet.com/;);
exit();
HTH

Cesar

Matt MacLeod wrote:
John,

Have tried this but unfortunately had no effect.

Everything appears to fine if the session variable does not exist ie: 
the user is redirected to the log in page.

It's just when the user has logged in and the session is set that IE 
throws it's toys out of the pram.

Cheers,
Matt
On Friday, December 12, 2003, at 03:15 PM, CPT John W. Holmes wrote:

From: Matt MacLeod [EMAIL PROTECTED]

if (!ISSET($_SESSION['loggedin'])) {
header(Location: /admin/login/);


put exit(); after your header redirect and use a full URL for your 
location.

---John Holmes...

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php