michael at favias.org
Tue Mar 27 17:27:06 UTC 2007
Gabor Hojtsy wrote:
> Michael Favia wrote:
>> Karoly Negyesi wrote:
>>> empty and isset are the same speed and do not throw notices. if
>>> something is not set or NULL, then isset is TRUE. if something is
>>> not set or NULL or empty array, 0 or '' or '0' then empty is TRUE.
>> And by TRUE he means FALSE. Or possibly !isset() or !empty(). You get
>> the point. To be clear the following two statements are both TRUE:
>> If something is not set or NULL, then isset() is FALSE. if something
>> is not set or NULL or empty array, 0 or '' or '0' then empty() is
>> If something is not set or NULL, then !isset() is TRUE. if something
>> is not set or NULL or empty array, 0 or '' or '0' then !empty() is
>> That is all.
> Hah, and by FALSE, you mean TRUE ;) isset() cannot be FALSE the same
> time empty() is FALSE, which is what you have written above...
Doh! Thats what I get for copy, paste, editing and not typing the silly
thing out. Anyone know of a good email client with a built in php
debugger? ;) Yes, my mistake please defer to that cheat sheet which
basically says the above (if you switch my last booleans in each
statement) in a much more coherent way.
Michael Favia michael at favias.org
tel. 512.585.5650 http://michael.favias.org
More information about the development