I think that would try to set $login=1. Need two == > Have you tried: > <?php if (!$login=1) {header("Location: loginerror.php");)?> > > -----Original Message----- > From: Daniel Clark [mailto:dclark@xxxxxxxxxx] > Sent: Friday, April 30, 2004 4:19 PM > To: matthew perry > Cc: php-db@xxxxxxxxxxxxx > Subject: Re: headers and if statements > > > Hum. Is $logIn null at times?!?! > >> <?if($logIn != 1) {header("Location: loginError.php");}?> >> >> Why does this direct me to loginError.php even when $logIn = 1? >> >> - Matt > > -- > 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 > > -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php