Created
September 18, 2013 06:51
-
-
Save anova/6605426 to your computer and use it in GitHub Desktop.
phptal multiple if priority issue solved with brackets.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<h1 tal:attributes="class php:repeat.current_item.number == 1 ? 'one' | |
: (repeat.current_item.number == 2 ? 'two' | |
: (repeat.current_item.number == 3 ? 'three' : NULL))" | |
tal:content="repeat/current_item/number" | |
tal:repeat="repeat_item collection"></h1> | |
<!-- collection bind from php code --> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment