On Thu, 2002-07-25 at 10:21, Ed Grimm wrote:
> Bad code.  SELECTED should be quoted.  As you have it here, perl
> searches for a keyword SELECTED, and if it finds it, it uses whatever it
> finds.  Otherwise, it treats it as a string.  You want it to always
> treat it as a string.

I tried it with quotes and it still returned an error.  The code I
posted is from 1998 so I would not be surprised if it was not valid in
version 2 or even later versions of 1.3 for that matter.

But if memory serves correct, that code was recommended by Gerald at
some point because I don't remember being that clever in 1998 :)

Aaron

> 
> Ed
> 
> On 25 Jul 2002, Aaron Johnson wrote:
> 
> > I was digging up some old code and thought I would run it through 2.08b,
> > I was aware of the foreach with no parentheses change, which this code
> > had, but this block of code now throws an error as well:
> > 
> > [+ if ($result1->[$count][3] eq "Regular After") {SELECTED} +]
> > 
> > It provides a dynamic "selected" inside of a select form element.  Is
> > this type of behavior no longer support in version 2?  Should this type
> > of coding be avoided regardless of version?
> > 
> > Aaron Johnson
> > 
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to