Re: variable issue

From: Date: Fri, 09 Nov 2001 19:39:27 +0000
Subject: Re: variable issue
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-74046@lists.php.net to get a copy of this message
replace the if statement if(!$dte) with if (!isset($dte)) ----- Original Message ----- From: "Johnson, Kirk" <kjohnson@zootweb.com> To: "PHP General" <php-general@lists.php.net> Sent: Friday, November 09, 2001 2:35 PM Subject: RE: [PHP] variable issue > The else clause can be removed, since it is not doing anything. What is the > error message? > > Kirk > > > Hey everyone, I need some help with a variable issue. How can > > I delcare a variable and then if a url variable of the same > > name is present use that value instead? > > > > this is what I have: > > if(!$dte) > > { > > $dte=date("j", time()+$ctime); > > } > > else > > { > > $dte=$dte; > > } > > and this causing an error in the 'if' expression. > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > >

« previous php.general (#74046) next »