Re: A follow up on my question about good coding practice [isset]

From: Date: Mon, 07 Jun 2004 06:06:45 +0000
Subject: Re: A follow up on my question about good coding practice [isset]
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-187769@lists.php.net to get a copy of this message
how about: if (trim($foo) != '') Respectfully, Ligaya Turmelle "Al" <news@ridersite.org> wrote in message news:20040606234452.31511.qmail@pb1.pair.com... > I could use one additional clarification regarding good practice. > > As I understand the php manual the following is acceptable. > > $foo= TRUE; > > if($foo) do.............. ; > > where $foo is a binary; but not a variable. > > Use isset($var) for variables and be careful with $var= ' '; etc. > because $var is assigned, i.e., "set".

« previous php.general (#187769) next »