RE: [PHP] isset not functioning

2009-08-03 Thread Yuri Yarlei
Io, try do like this: You should use $_POST for the security, using $_REQUEST some users can pass a inject or someting to crash the aplication, and addslashes is for more security $firstName = addslashes($_POST['firstname']); if(isset($firstName) && !empty($firstName)) { $name = $

Re: [PHP] isset not functioning

2009-08-03 Thread Steve Brown
> if(isset($_REQUEST['firstname']) && !empty($RESULT['firstname'])) { >  $name = $_REQUEST['firstname']; >  } else { >  $name = 'Sir or Madam'; > } > > Can anyone see any problems with the code? Your conditional will never evaluate to true. What is $RESULT? Where did it come from? $RESULT is no

Re: [PHP] isset not functioning -RESOLVED

2009-08-03 Thread Allen McCabe
Thanks! On Mon, Aug 3, 2009 at 10:13 AM, Andrew Ballard wrote: > On Mon, Aug 3, 2009 at 1:08 PM, Allen McCabe > wrote: > > I created a simple survey for my work website, most of the PHP is on my > > process.php document, which is referenced by a form on a seperate page > > containing the form w

Re: [PHP] isset not functioning

2009-08-03 Thread Ollisso
On Mon, 03 Aug 2009 20:11:44 +0300, "Parham Doustdar" wrote: Your if-statement should be like this: [code] if(isset($_REQUEST['firstname']) && !empty($_REQUEST['firstname'])) { ... } [/code] Or even: [code] if(!empty($_REQUEST['firstname'])) { ... } [/code] Because empty will also check

Re: [PHP] isset not functioning

2009-08-03 Thread Parham Doustdar
Your if-statement should be like this: [code] if(isset($_REQUEST['firstname']) && !empty($_REQUEST['firstname'])) { ... } [/code] -- --- Contact info: Skype: parham-d MSN: fire_lizard16 at hotmail dot com email: parham90 at GMail dot com "Allen McCabe" wrote in message news:657acef20908031008nc

Re: [PHP] isset not functioning

2009-08-03 Thread Andrew Ballard
On Mon, Aug 3, 2009 at 1:08 PM, Allen McCabe wrote: > I created a simple survey for my work website, most of the PHP is on my > process.php document, which is referenced by a form on a seperate page > containing the form with the method of "post". > > On my process.php page, the script obtains the