Quantcast
Channel: Ariba Exchange: Message List
Viewing all articles
Browse latest Browse all 3363

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?

$
0
0

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


Viewing all articles
Browse latest Browse all 3363

Trending Articles