Re: if statement

From: Date: Thu, 20 Sep 2001 13:49:16 +0000
Subject: Re: if statement
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-67989@lists.php.net to get a copy of this message
<Original message> From: Jeb Anderson Scarbrough <jebscarbrough@hotmail.com> Date: Thu, Sep 20, 2001 at 09:46:13AM -0400 Message-ID: <F27ohvTMGz1iD0CWlto0000260f@hotmail.com> Subject: [PHP] if statement > This seems to be a simple questions, but it is baffling me for some reason. > How do I create an if statement with multiple conditions. For example, I > cannot get either of these to work correctly: > > if(isset($REMOTE_USER) && $AUTH_TYPE='securid') { > // do something > } else { > // do something else > } > > OR > > if((isset($REMOTE_USER)) && ($AUTH_TYPE='securid')) { > // do something > } else { > // do something else > } > > > Thanks. </Original message> <Reply> I think your problem isn't really the if-statement itself. You should use == io =. So it would be: if(isset($REMOTE_USER) && $AUTH_TYPE=='securid') { ^^ ^^ </Reply> -- * R&zE: -- »»»»»»»»»»»»»»»»»»»»»»»» -- Renze Munnik -- DataLink BV -- -- E: renze@datalink.nl -- W: +31 23 5326162 -- F: +31 23 5322144 -- M: +31 6 21811143 -- -- Stationsplein 82 -- 2011 LM HAARLEM -- Netherlands -- -- http://www.datalink.nl -- ««««««««««««««««««««««««

« previous php.general (#67989) next »