cancel
Showing results for 
Search instead for 
Did you mean: 

Handling Namspaces in XSLT xpaths...

HarshC
Active Participant
0 Kudos

Hi,

I'm trying to generate the SOAP envelope using XSLT mapping. The source message to my mapping program, contains two fields:

a. username

b. pwd

But they come in with attached namespaces like ns1. How do I specify the xpath to get the data from them?

Regards,

Harsh

Accepted Solutions (1)

Accepted Solutions (1)

udo_martens
Active Contributor
0 Kudos

Hi Harsh,

-me again -

put the namespace declaration into the stylesheet element. like

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:ns1="namespace1">

Now you can select with

<xsl:value-of select="//ns1:a.username"/>

Regards,

Udo

Answers (1)

Answers (1)

HarshC
Active Participant
0 Kudos

And you solved the problem again

Thanks,

Harsh