Smartsite SXML CopyCode image Copy Code
<se:sqlquery>
 <se:parameters>

<se:parameter name="sql">
   select 1 as nr, 1 as level, 'Root' as title
   union select 2, 2, 'Product'
   union select 3, 3, 'Smartsite'
   union select 4, 3, 'SmartIets'
   union select 5, 3, 'SmartNL'
   union select 6, 2, 'Support'
   union select 7, 3, 'Support 4.5'
   union select 8, 4, 'Installation'
   union select 9, 4, 'Configuration'
   union select 10, 4, 'Development'
   union select 11, 5, 'Components'
   union select 12, 5, 'COM SDK'
   union select 13, 5, 'Device driver kit'
   union select 14, 3, 'Support 5'
  </se:parameter>

<se:parameter name="format">

  <se:rowformat>
    <li>
     {this.field(nr)} = {this.field(title)} ({this.field(level)})
     {this.childlevelresult()}
    </li>
   </se:rowformat>

  <se:levelformat groupby="this.field(level)">
    <ul style="background-color: #ffa0a0;">
     {this.levelresult()}
    </ul>
   </se:levelformat>

  <se:levelformat match="even">
    <ul style="background-color: #a0a0ff;">
     {this.levelresult()}
    </ul>
   </se:levelformat>

  <se:levelformat match="3">
    <ul style="background-color: #ffffa0;">
     {this.levelresult()}
    </ul>
   </se:levelformat>

  </se:parameter>
 </se:parameters>
</se:sqlquery>
Example Result CopyCode image Copy Code
<ul style="background-color: #ffa0a0;">
     
    <li>
     1 = Root (1)
     
    <ul style="background-color: #a0a0ff;">
     
    <li>
     2 = Product (2)
     
    <ul style="background-color: #ffffa0;">
     
    <li>
     3 = Smartsite (3)
     
    </li>
   
    <li>
     4 = SmartIets (3)
     
    </li>
   
    <li>
     5 = SmartNL (3)
     
    </li>
   
    </ul>
   
    </li>
   
    <li>
     6 = Support (2)
     
    <ul style="background-color: #ffffa0;">
     
    <li>
     7 = Support 4.5 (3)
     
    <ul style="background-color: #a0a0ff;">
     
    <li>
     8 = Installation (4)
     
    </li>
   
    <li>
     9 = Configuration (4)
     
    </li>
   
    <li>
     10 = Development (4)
     
    <ul style="background-color: #ffa0a0;">
     
    <li>
     11 = Components (5)
     
    </li>
   
    <li>
     12 = COM SDK (5)
     
    </li>
   
    <li>
     13 = Device driver kit (5)
     
    </li>
   
    </ul>
   
    </li>
   
    </ul>
   
    </li>
   
    <li>
     14 = Support 5 (3)
     
    </li>
   
    </ul>
   
    </li>
   
    </ul>
   
    </li>
   
    </ul>