|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Question about Context Changes in XSLT Questions and A
When I tested the XPath:A/C[postion()=2] and A/*[position()=2 and self::C], they gave me the same results. So are they the same or not? Thanks XML: <?xml version="1.0" standalone="yes"?> <a> <c>c1<d>d11</d><d>d12</d> <d>d13</d><d>d14</d></c> <c>c2<d>d21</d><d>d22</d> <d>d23</d><d>d24</d></c> <c>c3</c> <c>c4</c> </a> XSL: <?xml version="1.0"?> <xsl:stylesheet version="1.0" xmlns:xsl='http://www.w3.org/1999/XSL/Transform'> <xsl:template match="/"> <xsl:apply-templates/> </xsl:template> <xsl:template match="a/*[position()=2 and self::c]"> <td>(<xsl:value-of select="."/>)</td> </xsl:template> </xsl:stylesheet> Mingdong (Don) Yao 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








