[PHPTAL] tal:equal ?!

2011-04-13 Thread Ciprian Voicu
I've encountered lots of times the need to compare one or more pairs of values so I used php: modifier, but let's say would be more professional using some internal tal way instead of php native comparison way. eg: print some good content here it will be something more likely to use: print some

Re: [PHPTAL] tal:equal ?!

2011-04-13 Thread Robert Goldsmith
Hello :) It wouldn't work quite as you suggest because of how you use tales but we have an 'equal' tale as part of Ztal that does pretty much the same thing. You use it as follows: print some good content here The | symbol can be considered an 'or' where if the first statement fails or return

Re: [PHPTAL] tal:equal ?!

2011-04-13 Thread Kornel Lesiński
On Wed, 13 Apr 2011 14:45:31 +0100, Ciprian Voicu wrote: I've encountered lots of times the need to compare one or more pairs of values so I used php: modifier, but let's say would be more professional using some internal tal way instead of php native comparison way. eg: print some good con

[PHPTAL] PHPTAL and ZTal

2011-04-13 Thread Alexander Compton
I am pretty new PHPTAL, and Zend Framework, but was happy to run accross ZTal. How do you get ZTal to use hyphenated view names (e.g. product-description.xhtml) instead of the CamelCasing it currently does? Is there a website where all the useful Tales are located for PHPTAL? Of there is another

[PHPTAL] Want an alias for tal:attributes

2011-04-13 Thread romtek
When there's a lot of code on a page, being able to use as little text as possible is very desirable. I'd like to be able to use a short alias for tal:attributes. E.g. tal:attr. It's intuitive and familiar to people from other libraries. ___ PHPTAL mailin

Re: [PHPTAL] tal:equal ?!

2011-04-13 Thread Tjerk Meesters
For the and operation I've written a modifier that turns all its arguments into an array of booleans and then uses array_mult() to determine the outcome for tal:condition. array_sum could be used for the or-operation ;) On Apr 14, 2011 2:27 AM, "Kornel Lesiński" wrote: > On Wed, 13 Apr 2011 14:45