I have been sloppy in teh past and just used if($submit) blah blah blah
not sure of ramifications, but seems to work unless $submit is "false" or not set. again, take with grain of salt, other suggestions (especially isset) are much more certain. Dave >-----Original Message----- >From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] >Sent: Friday, March 15, 2002 3:46 PM >To: Daniel Negron/KBE >Cc: [EMAIL PROTECTED] >Subject: Re: [PHP] Re: Undefined Variable in IF...ELSE IF ...ELSE IF >(NEWBIE ?) > > >On Fri, 15 Mar 2002, Daniel Negron/KBE wrote: >> Thank You Charlie. I also found out that I needed to put an "@" symbol >> infrom of the string. This stopped it from throwing me an error. >> >> If(@$submit) blah blah blah > >Better yet, use: > > if (isset($submit)) blah blah blah > >That explicitly checks to see whether the variable has been defined >previously in the run, which makes your code easier to understand and >avoids the klugey @. > >miguel > > >-- >PHP General Mailing List (http://www.php.net/) >To unsubscribe, visit: http://www.php.net/unsub.php > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php