This line was removed.
This word was removed. This word was added.
This line was added.
Changes (5)View Page History
|h3. Development and Bug Reporting |
|Bugs can be filed here: [http://github.com/splittingred/If/issues] |
|h2. Usage |
The If snippet can be called using the tags:
or, in case your subject can be modified before the resource cache get cleared use the uncached syntax:
|When using the If snippet for checking a resource field or template variable (or other value that doesn't change before the cache does), be sure to use the *cached* snippet call to check the condition to make sure it doesn't need to process on every request. |
&then=`This resource is not visible in the menu.`
&else=`This resource shows up in the menu in spot [[*menuindex]].`
As requested an example with inarray.
&then=`This text will show if id is 3 or 4.`
&else=`This text is printed for all other resource id's.`