Howdy folks - I'm wondering how I might limit the comparisons in velocity templates to only boolean conditions.
For example: #if ($value > 20) HIGHLIGHTED BUTTON #else stdbutton #end would throw an exception and would need to be written with a context containing "IS_OVER_LIMIT", new Boolean() and this template: #if ($IS_OVER_LIMIT) HIGHLIGHTED BUTTON #else stdbutton #end Another example: #if ($widget.size == "LARGE") large #else not large #end would throw an exception and would need to be written as: #if ($widget.size.isLarge()) large #else not large #end The question here is academic at this point. I do not care to argue about why this might be good/bad/weird, nor do I want to hear how it could be done in another engine. I'm just curious to know how one might go about messing with Velocity to alter it's behaviour as described. Maybe I'll learn something in the process of looking. :-) Thanks! Timo --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
