|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: following-sibling
Hi,
> Hello again,
> I have this part of xml file and I wanna search in a row for
> the value ':
> 139597.1' and get its sibling 'Status: RONY'.
[snip]
> I'm using this xsl but not working. Plz can u tell me what's wrong?
> Thx again.
>
> ...
> <xsl:template match="body/center/table/tr/td/table/tr/td/small">
> <xsl:if test="contains(., ': 139597.1')">
> <b> Tar Status is : </b>
> <xsl:value-of select="normalize-space(following-sibling::tr
> [position() = 2]/td/small)"/>
> </xsl:if>
> </xsl:template>
<xsl:template match="body/center/table/tr/td/table/tr/td/small">
<xsl:if test="contains(., ': 139597.1')">
<b> Tar Status is : </b>
<xsl:value-of select="normalize-space(following::tr[2]/td[2]/small)"/>
</xsl:if>
</xsl:template>
You might want to do something about those match patterns, you could probably simplify them.
Jarno - having trouble finding anything fast enough to listen to, settling for Feindflug: Glaubenskrieg
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








