Location: PHPKode > scripts > XIRE > demo/index.tpl
<?xml version="1.0" encoding="UTF-8"?>
<document xmlns:xirl="http://ns.forizon.com/XIRL">
    <custom><xirl:value-of variable="variable" /></custom>
    <list>
      <xirl:for id="main" each="var">
        <key><xirl:value-of variable="key" /></key>
        <value><xirl:value-of variable="value" /></value>
      </xirl:for>
    </list>
    <content>loop through each item in the variable called "var", and display the key and value information provided by the programmer</content>

    <xirl:if variable='false'>
      <custom>false is true</custom>
    </xirl:if>
    <xirl:else-if variable='true'>
      <custom>true is true</custom>
    </xirl:else-if>
    <xirl:else>
      <custom>shouldn't display</custom>
    </xirl:else>

    <xirl:if variable='false'>
      <custom>false is true</custom>
    </xirl:if>
    <xirl:else>
      <custom>false is false</custom>
    </xirl:else>
</document>
Return current item: XIRE