Re: and or statement
| From: | Charles Fowler | Date: | Fri, 30 Aug 2002 00:49:30 +0000 |
| Subject: | Re: and or statement | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-114573@lists.php.net to get a copy of this message | ||
PHP and MYSQL Web Development manual by Welling and Thompson states
that logical operators are as follows:
_______________________________________________________________________________
Operator Name Use Result
_______________________________________________________________________________
! NOT !$b Returns true if
$b is false and vice versa
&& AND $a && $b Returns true if both $ a
and $b are true; otherwise false
| | OR $a | | $b Returns true
if either $ a or $b are true; otherwise false
and AND $a and $b Same as && but with
lower precedence
or OR $a or $b Same as | | but with
lower precedence
_______________________________________________________________________________
Just wanted to touch on the matter of the little fact that " and " and "
or " can be used in PHP but the order of precedence.
Hope this is helpful
¬¬Chuck¬¬