RE: [PHP] conditional statement problems

2002-10-01 Thread Ford, Mike [LSS]
> -Original Message- > From: Pablo Oliva [mailto:[EMAIL PROTECTED]] > Sent: 01 October 2002 08:11 > To: [EMAIL PROTECTED] > Subject: [PHP] conditional statement problems > > > $title_err = ($adTitle == "") ? 1 : strlen($adTitle) > 50 ? 2 : 0; &g

Re: [PHP] conditional statement problems

2002-10-01 Thread René Moonen
René Moonen wrote: > Pablo Oliva wrote: > >> $title_err = ($adTitle == "") ? 1 : strlen($adTitle) > 50 ? 2 : 0; >> >> Can anyone tell me why this is not evaluating correctly (returning a >> value of 1) when $adTitle is an empty string? >> >> >> >> > I have no idea... but if you change your code

Re: [PHP] conditional statement problems

2002-10-01 Thread René Moonen
Pablo Oliva wrote: >$title_err = ($adTitle == "") ? 1 : strlen($adTitle) > 50 ? 2 : 0; > >Can anyone tell me why this is not evaluating correctly (returning a >value of 1) when $adTitle is an empty string? > > > > I have no idea... but if you change your code to this, it works: $title_err = ($

Re: [PHP] conditional statement problems

2002-10-01 Thread Tom Rogers
Hi, Tuesday, October 1, 2002, 5:11:08 PM, you wrote: PO> $title_err = ($adTitle == "") ? 1 : strlen($adTitle) > 50 ? 2 : 0; PO> Can anyone tell me why this is not evaluating correctly (returning a PO> value of 1) when $adTitle is an empty string? It is right according to your expression, try

[PHP] conditional statement problems

2002-09-30 Thread Pablo Oliva
$title_err = ($adTitle == "") ? 1 : strlen($adTitle) > 50 ? 2 : 0; Can anyone tell me why this is not evaluating correctly (returning a value of 1) when $adTitle is an empty string? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php