cancel
Showing results for 
Search instead for 
Did you mean: 

Edit XML Header

former_member309357
Participant
0 Kudos

Hello Gurus,

We are using PI 7.11. We have a requirement PROXY to FILE in which the receiver expecting the below XML header:

Actual:

<?xml version="1.0" encoding="UTF-8"?>

Required:

<?xml version="1.0" encoding="UTF-8" standalone="true"?>

Please let me know how to achieve this..

Thanks

Ravi

Accepted Solutions (1)

Accepted Solutions (1)

former_member190293
Active Contributor
0 Kudos

Hi Ravi!

I don't know any details about your current mapping and your message structure.

Thus, here is an XSL transformation that you can use as very last message mapping in your operation mapping. It just copies current payload and adds the required attribute to XML message header:

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
    <xsl:output standalone="yes"/>
    <xsl:template match="/">
        <xsl:copy-of select="."/>
    </xsl:template>
</xsl:stylesheet>

Regards, Evgeniy.

Answers (1)

Answers (1)

former_member190293
Active Contributor

Hi Ravi!

You can use XSLT transformation to add required attribute to your XML message header:

<xsl:output standalone="yes"/>

Regards, Evgeniy.

former_member309357
Participant
0 Kudos

Hi Kolmakov,

As I am new to XSLT mapping, request you to please provide full code.

Many thanks in advance.

Thanks

Ravi