AquaLogic User Interaction Development Guide

     Previous Next  Open TOC in new window   View as PDF - New Window  Get Adobe Reader - New Window
Content starts here

Evaluating Expressions Using Adaptive Tags

The pt:logic.boolexpr, intexpr, stringexpr and containsexpr tags work with the pt:logic.if tag to evaluate a range of expressions.

The sample code below determines whether the current value for the variable "title" is set to "Administrator". Variables can be set using the pt:logic.data or pt:logic.variable tags.
<pt:logic.stringexpr pt:expr="($title) == Administrator" pt:key="boolvalue"/>
<pt:logic.if pt:expr="$boolvalue">
<pt:logic.iftrue>
This is displayed if expr evaluates to true. 
</pt:logic.iftrue>
<pt:logic.iffalse>
This is displayed if expr evaluates to false. 
</pt:logic.iffalse>
</pt:logic.if>
For details on using shared variables, see Using Shared Variables in Adaptive Tags.

  Back to Top      Previous Next