Re: [PHPTAL] Re: selected=

2009-06-16 Thread Tjerk Meesters
Hi, What I meant was: tal:attributes="selected exists: isSelected" Always try to avoid using php: constructs in your templates ;-) Bets, Tjerk 2009/6/16 Kornel Lesiński : > On 16-06-2009 at 16:16:53 Igor Sverkos > wrote: > >> Hi, >> >> Tjerk Meesters wrote: >>> >>> As Kornel mentioned, thi

Re: [PHPTAL] Re: selected=

2009-06-16 Thread Kornel Lesiński
On 16-06-2009 at 16:16:53 Igor Sverkos wrote: Hi, Tjerk Meesters wrote: As Kornel mentioned, this is fixed in the repos and it can be made to work for older versions by using "exists: isSelected" instead of "isSelected | nothing" I can use "exists" in PHPTALES? E.g. ...? No. Use isset(

[PHPTAL] Re: selected=

2009-06-16 Thread Igor Sverkos
Hi, Tjerk Meesters wrote: > As Kornel mentioned, this is fixed in the repos and it can be made to > work for older versions by using "exists: isSelected" instead of > "isSelected | nothing" I can use "exists" in PHPTALES? E.g. ...? -- Regards, Igor _

Re: [PHPTAL] Re: selected=

2009-06-15 Thread Tjerk Meesters
Hi, As Kornel mentioned, this is fixed in the repos and it can be made to work for older versions by using "exists: isSelected" instead of "isSelected | nothing" Hope that helps :) On 6/16/09, Igor Sverkos wrote: > Hi, > > Tjerk Meesters wrote: >> Hmm I don't think using "selected" as the value

[PHPTAL] Re: selected=

2009-06-15 Thread Igor Sverkos
Hi, Tjerk Meesters wrote: > Hmm I don't think using "selected" as the value is the solution to the > exact problem here, because phptal does understand the so called > binary attributes, such as selected and checked. > > Seems like the '| nothing' is causing the expression to change type > and di

[PHPTAL] Re: selected="selected" doesn't work for me

2009-06-15 Thread Igor Sverkos
Hi, Scott Trevithick wrote: > The problem is that your array associates the PHP boolean value TRUE with the > key 'isSelected'. 1 is the functional equivalent of TRUE in many languages, > hence PHPTAL gives you 1 since you specified TRUE. Use the string 'selected' > instead. Mhh... I thought TAL

[PHPTAL] Re: selected="selected" doesn't work for me

2009-06-14 Thread Scott Trevithick
The problem is that your array associates the PHP boolean value TRUE with the key 'isSelected'. 1 is the functional equivalent of TRUE in many languages, hence PHPTAL gives you 1 since you specified TRUE. Use the string 'selected' instead. $options = array( array( 'label' => 'Option1',