Chris Huegle wrote:
[% IF 'bar' >= 'foo' %] translates to
if ('bar' >= 'foo') { which returns true, since 1 == 1.

Chris,

I must apologize to you. You are quite correct as to the translation. I made the mistake of relying on the Badger book, which says (p138):

"The comparison operators ==, !=, <, <=, >, >= are also provided. Note that they always compare their operands as strings."

As far as I can see, there is nothing in the index about how to compare strings and I can't find anything either in the documentation at http://www.template-toolkit.org/.

Andy, how does one compare strings in TT?

Cheers, Dave


_______________________________________________ templates mailing list [EMAIL PROTECTED] http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to