WARNING: Most of this content (with the exception of the Mozilla 1.9 XPCOM reference) is very old, and can be expected to be out of date and possibly obsolete. For better XUL documentation, please visit the XUL hub at the Mozilla Developer Center.
Example: Iterate over parents of a node
This example demonstrates retrieving the parents of a starting node. In this case, we start at the Emu node, and retrieve its two parents.
<vbox datasources="animals.rdf" ref="http://www.some-fictitious-zoo.com/birds/emu">
<template>
<rule>
<conditions>
<content uri="?uri"/>
<member container="?parent" child="?uri"/>
<triple subject="?parent"
predicate="http://www.some-fictitious-zoo.com/rdf#name"
object="?name"/>
</conditions>
<action>
<label uri="?parent" value="?name"/>
</action>
</rule>
</template>
</vbox>
