Gossamer Forum
Home : Products : Gossamer Links : Discussions :

boolean conditions in if/elsif/else

Quote Reply
boolean conditions in if/elsif/else
What are the syntax restraints for if/elsif/else statements? Can we use AND/OR?

<%if Test1 && Test2 || Test3%>

Do this

<%%>

Do that

<%endif%>
Quote Reply
Re: [vicos2] boolean conditions in if/elsif/else In reply to
From Help:



If statements (as well as elseif statements) may contain multiple conditions using one of the two booleans: 'or' or 'and'.

It should be noted that it is not possible to mix both 'or' and 'and' in one complex if statement - you may, however, use the same boolean multiple times in one statement. (Brackets) are also not supported.


../admin/admin.cgi?do=help&topic=GT/Template.html
Quote Reply
Re: [Payooo] boolean conditions in if/elsif/else In reply to
oops, I missed that document - answers all my questions and more. thanks for pointing it out :)