开发者

how to retrieve attributes of XML using XSLT

say i have a LinkName , i will be able to retrieve the value of LinkName using XSLT, but how will retrive the value of href? i.e i need to retrieve the value of xyz as my output. Find the exact XML below from which i need to extract the value of href

<table border="1" align="center" >
  <tr>
        <td bgcolor="#99BBEE" >
              <A HREF="start.swe?C=Gt&amp;S=SSCS&amp;SWENeedContext=false&amp;_sn=0t9LLy7Y6Ciiwff5rq9XulU.O-prUFxaMoJv6vfreLDEwBbxbqJePuZ.S880KNPu&amp;SWEBID=-1&amp;SWEC=2">
        开发者_StackOverflow社区            <font face="Arial" size="2">Calendar</font>
              </A>
        </td>
        <td bgcolor="#99BBEE" width="50%" align="center" valine="middle">
              <A HREF="start.swe?C=Gt&amp;S=SSCS0&amp;SWENeedContext=false&amp;_sn=0t9LLy7Y6Ciiwff5rq9XulU.O-prUFxaMoJv6vfreLDEwBbxbqJePuZ.S880KNPu&amp;SWEBID=-1&amp;SWEC=2">
                    <font face="Arial" size="2">Contacts</font>
              </A>
        </td>
  </tr></table>

my output should be the values of href..! please help


Your template for the node would be (as an example):

<xsl:template match="A">
    <xsl:value-of select="@HREF"/>
</xsl:template>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜