xsl-list
[Top] [All Lists]

Still Testing!!

2005-02-12 07:02:51
<?xml version="1.0"?>
<tree>
  <tree_node id="7" value="Test">
    <tree_node id="8" value="Test Sub"/>
      <tree_node id="9" value="Test Sub One">
      <tree_node id="10" value="Test Sub Two">
        <tree_node id=?11? value=?Test Sub Three?/>
      </tree_node>
    </tree_node>
  </tree_node>
</tree>

Given the structure above I am trying to use an xsl:if test that tests
whether a node is an immediate child of a particular node. ie: Node with id
8 Is the immediate child of node with id of 7.

<xsl:if test="parent::tree_node[(_at_)id=$c_node]">

</xsl:if>

Above is my attempt to achieve this, but doesn?t appear to work.

Thanks to those who have responded to my previous posts, I am still very
green to xsl so your insights are appreciated and are slowly helping me
understand this technology. 

Cheers, 
Adam 
 
NB: "Pray as if everything depended upon God and work as if everything
depended upon man."



--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



<Prev in Thread] Current Thread [Next in Thread>