Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Selecting a node based on its text value

From: "Anthony Jones" <Ant@------------.--->
To: NULL
Date: 11/9/2006 11:24:00 AM


"johns221b" <johns221b@d...> wrote in message
news:FE4E50FD-9572-4A55-BA25-E8A58EE62C3F@m......
>
>
> "TripleDiamonds" wrote:
>
> > if I have the following structure as my xml file
> >
> > <Items>
> >   <Item>
> >      <mytext>1</mytext>
> >      <items>
> >      </items>
> >   </item>
> >   <item>
> >     <mytext>2</mytext>
> >     <items>
> >       <item>
> >         <mytext>3</mytext>
> >         <items></items>
> >       </item>
> >       <item>
> >         <mytext>56</mytext>
> >         <items></items>
> >       </item>
> >       <item>
> >         <mytext>565</mytext>
> >         <items></items>
> >       </item>
> >       <item>
> >         <mytext>33</mytext>
> >         <items></items>
> >       </item>
> >    </items>
> >  </item>
> >  <item>
> >    <mytext>89</mytext>
> >    <items></items>
> >  </item>
> >
> > how would I select the item node that contained the mytext node where
> > the text is 565?  is there a  way to do this type of query?  I have
> > seen examples where the user does it using an attribute but have been
> > unsuccessfull at finding an example where it is based on the text
> > inside the node.....
> >
> > any help would be appreciated.
> > where each item can contain an items collection within itself
>
>
>
> <xsl:for-each select="//Items/item[./mytext=565]">
>

select="//item[mytext='565']"





transparent
Print
Mail
Digg
delicious
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent