iselseif Element

Use with <iselseif> to specify a subcondition off an <isif> tag.

Syntax 

1<isif condition = if_expression>
2  ...
3<iselseif condition = elseif_expression> //0 or more
4  ...
5</iselseif>
6<iselse>
7  ...
8</isif>
condition

Allowed data type: string or expression.

elseif_expression evaluates to a boolean value. If the <isif> condition is true, the system executes the code immediately following the <isif > tag, ignoring the enclosed <iselseif> and <iselse> tags. If the <isif> condition is false, the system ignores the code immediately following the <isif> tag, and then tests each <iselseif> condition in order. When the system finds a true <iselseif> condition, the system executes the code immediately following the <iselseif> tag and ignores any remaining <iselseif> and <iselse> tags. If all <iselseif> conditions are false, the system executes the code following the <iselse> tag.

Example 

In this example, the system determines if the product name equals ‘case’ or ‘bag’. If it does, it shows the word Monogram. If it doesn’t, it continues processing.

1<thead>
2  <tr>
3    <th>Qty.</th>
4    <th colspan="2">Description</th>
5  <isif condition ="{$pdict.Product.name} == 'case'}">
6    <th>Monogram</th>
7  <iselseif condition ="{$pdict.Product.name} == 'bag'}">
8    <th>Monogram</th>
9  <iselse>
10    <th>Unit Price</th>
11  </isif>
12    <th>Item Total</th>
13    <th>&nbsp;</th>
14  </tr>
15</thead>