Index

Example: Generate a listbox of items with multiple columns

This example shows how to create a listbox with mutliple columns. Each column displays the value for a different predicate. The columns are defined outside the template but will be added inside the listbox.

View   View Data Source

<listbox datasources="animals.rdf" ref="http://www.some-fictitious-zoo.com/mammals">
  <listcols>
    <listcol flex="1"/>
    <listcol flex="1"/>
    <listcol flex="1"/>
  </listcols>
  <template>
    <listitem uri="rdf:*">
      <listcell label="rdf:http://www.some-fictitious-zoo.com/rdf#name"/>
      <listcell label="rdf:http://www.some-fictitious-zoo.com/rdf#species"/>
      <listcell label="rdf:http://www.some-fictitious-zoo.com/rdf#specimens"/>
    </listitem>
  </template>
</listbox>
Copyright © 1999 - 2005 XULPlanet.com