2 Replies Latest reply on Feb 27, 2015 10:51 AM by Debbie Curtis-Magley

    Is it possible to send a PunchOut Order Message directly in cXML format to some URL or is it a must to have it wrapped in a HTML FORM?

    Peter Jarunek Newbie

      Hi friends,

       

      I have following situation: We create a cXML PunchOut Order Message and need to send it to Ariba. Following the process, this already contains products selected by the customer and get's validated successfully to DTD.

      I know it is possible to wrap the cXML message to a HTML form parameters cxml-urlencoded od cXML-base64.

      My question is - is this the only way how the POOM message can get processed? Isn't there some "server-side" "backend" processing possible? I mena, sending cXML as a XML directly to some URL?

      Or is this HTML wrapping always necessary and only supported?

       

      Thanks,

      Peter

        • Re: Is it possible to send a PunchOut Order Message directly in cXML format to some URL or is it a must to have it wrapped in a HTML FORM?
          Debbie Curtis-Magley Master

          Hi Peter:

           

          Thanks for sharing your question.I shared your inquiry with our seller support team. If you haven't done so already, please contact the team at commerceassistance@ariba.com for assistance.

           

          Debbie Curtis-Magley

          Ariba Exchange Community Manager

          • Re: Is it possible to send a PunchOut Order Message directly in cXML format to some URL or is it a must to have it wrapped in a HTML FORM?
            Debbie Curtis-Magley Master

            Hi Peter:

             

            I heard back from the Commerce Assistance team. Here's the guidance that they offered, courtesy of the Ariba Catalog team:

             

            When a PunchOut website embeds the PunchOutOrderMessage in the cXML-urlencoded, hidden form field, it must ensure that special Extensible Markup Language (XML) and Hypertext Markup Language (HTML) characters are properly encoded for the multiple layers of transport.  The preferred alternative for this specialized encoding utilizes the Base64-encoded hidden field, which additionally supports extended characters that the cXML-urlencoded field does not. 

            In the PunchOutOrderMessage, encode these characters:

            • " -> " (This needs encoding because the PunchOutOrderMessage is embedded inside the input cXML-urlencoded attribute's value. An actual quotation mark indicates the value's end to the browser.)
            • & -> & (This character, both a special XML character and a special HTML character, must be double-encoded. The browser actually POSTS this to its destination as &, the correct encoding for an ampersand in a cXML document.)

              Additionally, if any of the element content contains angle brackets (less than or greater than ("<" or ">")), escape these as well: 

            • < -> &amp;lt;
            • > -> &amp;gt;

            Both of these special XML and HTML characters are double-encoded.  For example, if a product description is: "2" x 4" pine board, < 0.02" deviation (red & white)," the cXML-urlencoded field would look like this within the HTML source:

            <Description xml:lang=&quot;en&quot;>2&quot; x 4&quot; pine board, &amp;lt; 0.02&quot; deviation (red &amp;amp; white)</Description>

            However, using the Base64-encoded field, rather than the cXML-urlencoded field is preferred, since Base64-encoded data does not need any HTML special characters escaped.

             

            If you need further assistance, contact the Commerce Assistance team and asked to have your inquiry escalated to Technical Support.

             

            Regards,

             

            Debbie