<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: accept hosted does not work when a field contains an ampersand in Integration and Testing</title>
    <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/91816#M57627</link>
    <description>&lt;P&gt;Encountering this problem in 2025. Company Name or Address fields have &amp;amp; in the data, which throws a "Invalid or Missing Token" error when the Accept Hosted form is submitted. I know the ANET API xml escapes this data prior to sending the message to their servers, but it still breaks the submission when &amp;amp; is escaped to &amp;amp;amp;.&amp;nbsp;So as a work around I have changed &amp;amp; to "AND" to bypass this bug, but it really is a bug because &amp;amp; should be allowed in the post body&lt;/P&gt;</description>
    <pubDate>Thu, 19 Jun 2025 09:03:37 GMT</pubDate>
    <dc:creator>kschaller1979</dc:creator>
    <dc:date>2025-06-19T09:03:37Z</dc:date>
    <item>
      <title>accept hosted does not work when a field contains an ampersand</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/59501#M34084</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I believe there is a bug with the accept hosted page. When I create a&lt;BR /&gt;token with an address like "22 Hill &amp;amp; Dale Rd" I get a the token back&lt;BR /&gt;successfully but when going to the accept hosted page (both dev and&lt;BR /&gt;prod) it sais "Missing or invalid token."&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I replace the Ampersand with plain text like "22 Hill and Dale Rd",&lt;BR /&gt;the accept hosted page is displayed ok.&lt;BR /&gt;&lt;BR /&gt;Trying to send "22 Hill &amp;amp;amp; Dale Rd" also does not help.&lt;BR /&gt;We think the same problem exists for names, like company&lt;BR /&gt;name "Frank &amp;amp; Selma Enterprises".&lt;BR /&gt;&lt;BR /&gt;As fas as I know, an ampersand is a legal character in a JSON&lt;BR /&gt;string message.... What to do ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Btw sending %26 does seem to work for simple redirect accept hosted,&lt;/P&gt;&lt;P&gt;but then the message received in an iFrameCommunicator is truncatd...&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Thanks and kind regards,&lt;BR /&gt;Tom.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 23 Aug 2017 13:35:26 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/59501#M34084</guid>
      <dc:creator>teicher</dc:creator>
      <dc:date>2017-08-23T13:35:26Z</dc:date>
    </item>
    <item>
      <title>Re: accept hosted does not work when a field contains an ampersand</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/59547#M34130</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.developer.cybersource.com/t5/user/viewprofilepage/user-id/22226"&gt;@teicher&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://community.developer.cybersource.com/t5/user/viewprofilepage/user-id/22226"&gt;@teicher&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Btw sending %26 does seem to work for simple redirect accept hosted,&lt;/P&gt;
&lt;P&gt;but then the message received in an iFrameCommunicator is truncatd...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hmmm... When I try using %26 on my end, I get the full message passed to my IFrameCommunicator.html script, so I suspect there's some problem with the way that you're parsing the JSON in the message that's returned.&lt;/P&gt;</description>
      <pubDate>Wed, 20 Sep 2017 19:48:36 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/59547#M34130</guid>
      <dc:creator>Aaron</dc:creator>
      <dc:date>2017-09-20T19:48:36Z</dc:date>
    </item>
    <item>
      <title>Re: accept hosted does not work when a field contains an ampersand</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/62045#M36429</link>
      <description>&lt;P&gt;We're also experiencing this issue.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I noticed the authorize.net accept hosted page now has some javascript which prevents users from entering troublesome characters (like "&amp;amp;" or "&lt;SPAN class="_Tgc _s8w"&gt;è&lt;/SPAN&gt;") in the form, so that's a partial fix.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;BUT you can still pass these troublesome characters in the "getHostedPaymentPage" request, and then they will appear on the page, and then cause this same problem when submitting the form.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We got around this by just making sure we never pass any non-alphanumeric characters in the "GetHostedPaymentPage" request.&lt;/P&gt;</description>
      <pubDate>Thu, 08 Mar 2018 21:17:54 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/62045#M36429</guid>
      <dc:creator>eventespresso</dc:creator>
      <dc:date>2018-03-08T21:17:54Z</dc:date>
    </item>
    <item>
      <title>Re: accept hosted does not work when a field contains an ampersand</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/75591#M47151</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We also confirmed that this is still an issue and passing &amp;amp;amp; in the request causes the order summary page to error out and not display the order details. The chrome devtools console shows javascript errors on the page so I believe this is a bug with Authnet's hosted accept page.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there somewhere where we can officially log an bug with the Authnet dev team so that they can get this fixed?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 03 Apr 2021 18:19:35 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/75591#M47151</guid>
      <dc:creator>redcart</dc:creator>
      <dc:date>2021-04-03T18:19:35Z</dc:date>
    </item>
    <item>
      <title>Re: accept hosted does not work when a field contains an ampersand</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/91816#M57627</link>
      <description>&lt;P&gt;Encountering this problem in 2025. Company Name or Address fields have &amp;amp; in the data, which throws a "Invalid or Missing Token" error when the Accept Hosted form is submitted. I know the ANET API xml escapes this data prior to sending the message to their servers, but it still breaks the submission when &amp;amp; is escaped to &amp;amp;amp;.&amp;nbsp;So as a work around I have changed &amp;amp; to "AND" to bypass this bug, but it really is a bug because &amp;amp; should be allowed in the post body&lt;/P&gt;</description>
      <pubDate>Thu, 19 Jun 2025 09:03:37 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/accept-hosted-does-not-work-when-a-field-contains-an-ampersand/m-p/91816#M57627</guid>
      <dc:creator>kschaller1979</dc:creator>
      <dc:date>2025-06-19T09:03:37Z</dc:date>
    </item>
  </channel>
</rss>

