cancel
Showing results for 
Search instead for 
Did you mean: 

XSLT question

Former Member
0 Kudos

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........

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

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"/> -

Former Member
0 Kudos

Thanks guys.. we did a work around for this.....

Former Member
0 Kudos

<xsl:value-of select="@actioncode"/ >