Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Need XSLT

Posted on 2014-03-31
1
Medium Priority
?
371 Views
Last Modified: 2016-02-26
Hi,

I am getting a SOAP response like below:

<s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:a="http://www.w3.org/2005/08/addressing">
      <s:Header>
            <a:Action s:mustUnderstand="1">http://abcde/2011/02/25/abcde/abcde/abcde</a:Action>
      </s:Header>
      <s:Body>
            <StoreEventResponse xmlns="http://abcde/2011/02/25/abcde">
                  <StoreEventResult xmlns:b="http://abcde/2011/02/25/abcde" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
                        <b:Status>Successful</b:Status>
                        <b:TransmissionUID>63564440526</b:TransmissionUID>
                        <b:Messages xmlns:c="http://schemas.microsoft.com/2003/10/Serialization/Arrays"/>
                        <b:InternalUID>99f8a29e-9bc7-43c3-a0ef-e03d5f69cdd3</b:InternalUID>
                  </StoreEventResult>
            </StoreEventResponse>
      </s:Body>
</s:Envelope>

I need a XSLT to extract the below:

<StoreEventResponse xmlns="http://abcde/2011/02/25/abcde">
                  <StoreEventResult xmlns:b="http://abcde/2011/02/25/abcde" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
                        <b:Status>Successful</b:Status>
                        <b:TransmissionUID>63564440526</b:TransmissionUID>
                        <b:Messages xmlns:c="http://schemas.microsoft.com/2003/10/Serialization/Arrays"/>
                        <b:InternalUID>99f8a29e-9bc7-43c3-a0ef-e03d5f69cdd3</b:InternalUID>
                  </StoreEventResult>
            </StoreEventResponse>

Please help.

Regards
Pradeep
0
Comment
Question by:Pradeep0308
1 Comment
 
LVL 60

Accepted Solution

by:
Geert Bormans earned 2000 total points
ID: 39966269
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
     version="1.0">
    
    <xsl:template match="/" xmlns:s="http://www.w3.org/2003/05/soap-envelope">
        <xsl:copy-of select="//s:Body/*"/>
    </xsl:template>
    
</xsl:stylesheet>

Open in new window

0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many times as a report developer I've been asked to display normalized data such as three rows with values Jack, Joe, and Bob as a single comma-separated string such as 'Jack, Joe, Bob', and vice versa.  Here's how to do it. 
Create a Windows 10 custom Image with custom task bar and custom start menu using XML for deployment.
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …

971 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question