[If Expressions][Then]do this[/Then][Else]otherwise
- New in 4.0
Displays HTML conditionally
only if the expression is false.
To display some HTML (or execute WebDNA [xxx] tags) only if certain conditions
are met, place the text inside an [If] context.
The comparison, which may contain any [xxx] tags, is first evaluated to see
if it is true, and if true then the contained [Then]
context is executed (or simply displayed, if it's just HTML). If not true, then
the contained [Else] context is executed (or simply displayed, if it's just
HTML). See [Then] and [Else].
Example (normally you would put the following text into
a .tpl file on your server and use a web browser to link to it):
[If (("[username]"="Grant") | ([grandTotal]<100))
[Then]either username was Grant or grandTotal
was < $100 and it's not Feb 15, 2000 yet[/Then]
[Else]The complex expression wasn't
See [If] for description of full syntax.