on 05-10-2011 1:24 AM
Hi all,
Need help on reading attribute value of XML field in XSLT mapping .
Part of source code, where we want to read attribute actionCode value i.e., "Accepted".
<ResponseCriteria actionCode="Accepted">
<ChangeStatus>
<Code>Position Opening was created</Code>
<ReasonCode/>
<Reason>PositionID assiggned - 10939</Reason>
<Description/>
</ChangeStatus>
</ResponseCriteria>
We are able to reach till the location with below code in XSLT,
<xsl:value-of select="//*[local-name()='ResponseCriteria']"/>
This code is giving us values of Code & Reason fields.
How to get the values of attribute actionCode?? any ideas........
Rahul has correctly pointed that xsl:value-of can also be used to retrieve the value of attributes of XML elements.
<xsl:value-of select="@actioncode"/> -
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
<xsl:value-of select="@actioncode"/ >
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
24 | |
11 | |
9 | |
7 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.