<?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: Remove charset=utf-8 from HTTP POST in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085675#M1506598</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I had a similar problem and could resolve it by using APPEND_DATA instead of APPEND_CDATA. Likewise, SET_DATA instead of SET_CDATA might solve the issue for you. The data has to be provided as binary data then.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Stefan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 21 Aug 2014 12:52:55 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2014-08-21T12:52:55Z</dc:date>
    <item>
      <title>Remove charset=utf-8 from HTTP POST</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085672#M1506595</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm trying to do a HTTP POST via ABAP.  The application that I'm posting to does not like the "charset=utf-8" that is in the request.  I've been told that I need to remove it.  Does anyone know how to do this?  I'm not setting this field.  SAP is adding this charset automatically.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is the request:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;POST /hapld/tos/kdwhapltos HTTP/1.1&lt;/P&gt;&lt;P&gt;content-type: multipart/mixed; boundary=BOUNDARY; charset=utf-8&lt;/P&gt;&lt;P&gt;content-length: 2018&lt;/P&gt;&lt;P&gt;host: &lt;A href="https://community.sap.com/www.pld-certify.ups.com" target="test_blank"&gt;www.pld-certify.ups.com&lt;/A&gt;&lt;/P&gt;&lt;P&gt;user-agent: SAP Web Application Server (1.0;700)&lt;/P&gt;&lt;P&gt;accept-encoding: gzip&lt;/P&gt;&lt;P&gt;sap-trace: 3 &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--BOUNDARY&lt;/P&gt;&lt;P&gt;Content-type: application/x-www-form-urlencoded&lt;/P&gt;&lt;P&gt;Content-length: 128&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AppVersion=1.0&amp;amp;AcceptUPSLicenseAgreement=Yes&amp;amp;ResponseType=application/x-ups-pld&amp;amp;VersionNumber=V4R1&amp;amp;UserId=xxxxxx&amp;amp;Password=xxxxxx&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--BOUNDARY&lt;/P&gt;&lt;P&gt;Content-type: application/x-ups-binary&lt;/P&gt;&lt;P&gt;Content-length: 1396&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;020093  2010071800000006852703500   000000002*AA296007......etc&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;DEL&gt;BOUNDARY&lt;/DEL&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is my code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL METHOD cl_http_client=&amp;gt;create&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      host          = POST_HOST&lt;/P&gt;&lt;P&gt;      service       = '443'&lt;/P&gt;&lt;P&gt;      scheme        = '2'&lt;/P&gt;&lt;P&gt;      ssl_id        = 'ANONYM'&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   proxy_host    =  wf_proxy&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   proxy_service =  wf_port&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;    IMPORTING&lt;/P&gt;&lt;P&gt;      client        = http_client.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  http_client-&amp;gt;propertytype_logon_popup = http_client-&amp;gt;co_disabled.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  wf_user = '' .&lt;/P&gt;&lt;P&gt;  wf_password = '' .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  data: lv_value type string.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL METHOD http_client-&amp;gt;request-&amp;gt;set_header_field&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      name  = '~request_method'&lt;/P&gt;&lt;P&gt;      value = 'POST'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL METHOD http_client-&amp;gt;request-&amp;gt;set_header_field&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      name  = '~request_protocol'&lt;/P&gt;&lt;P&gt;      value = 'HTTP/1.1'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL METHOD http_client-&amp;gt;request-&amp;gt;set_header_field( name = '~server_protocol' value = 'HTTP/1.1' ).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL METHOD http_client-&amp;gt;request-&amp;gt;set_header_field&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      name  = 'HOST'&lt;/P&gt;&lt;P&gt;      value = POST_HOST.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL METHOD http_client-&amp;gt;request-&amp;gt;set_header_field&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      name  = '~request_uri'&lt;/P&gt;&lt;P&gt;      value = POST_URI.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL METHOD http_client-&amp;gt;request-&amp;gt;set_content_type&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      content_type = 'multipart/mixed; boundary=BOUNDARY'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL METHOD http_client-&amp;gt;REQUEST-&amp;gt;SET_HEADER_FIELD&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      NAME = 'Accept-Charset'&lt;/P&gt;&lt;P&gt;      VALUE = 'ISO-8859-1,utf-8;q=0.7,*;q=0.7'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; CALL METHOD http_client-&amp;gt;request-&amp;gt;SET_FORMFIELD_ENCODING&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      FORMFIELD_ENCODING = http_client-&amp;gt;request-&amp;gt;CO_ENCODING_URL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL METHOD http_client-&amp;gt;request-&amp;gt;set_cdata&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      data   = wf_string&lt;/P&gt;&lt;P&gt;      offset = 0&lt;/P&gt;&lt;P&gt;      length = rlength.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL METHOD http_client-&amp;gt;send&lt;/P&gt;&lt;P&gt;    EXCEPTIONS&lt;/P&gt;&lt;P&gt;      http_communication_failure = 1&lt;/P&gt;&lt;P&gt;      http_invalid_state         = 2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL METHOD http_client-&amp;gt;receive&lt;/P&gt;&lt;P&gt;    EXCEPTIONS&lt;/P&gt;&lt;P&gt;      http_communication_failure = 1&lt;/P&gt;&lt;P&gt;      http_invalid_state         = 2&lt;/P&gt;&lt;P&gt;      http_processing_failed     = 3.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CLEAR wf_string1 .&lt;/P&gt;&lt;P&gt;  wf_string1 = http_client-&amp;gt;response-&amp;gt;get_cdata( ).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Jul 2010 20:21:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085672#M1506595</guid>
      <dc:creator>tony_raimo2</dc:creator>
      <dc:date>2010-07-19T20:21:49Z</dc:date>
    </item>
    <item>
      <title>Re: Remove charset=utf-8 from HTTP POST</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085673#M1506596</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Tony, can you share with us how you solved your problem.?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 May 2012 20:34:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085673#M1506596</guid>
      <dc:creator>asdasd_asdasd</dc:creator>
      <dc:date>2012-05-10T20:34:13Z</dc:date>
    </item>
    <item>
      <title>Re: Remove charset=utf-8 from HTTP POST</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085674#M1506597</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Raimo, &lt;/P&gt;&lt;P&gt; I am also facing similar issue while posting messages via Http adapter Can you please let me know how you cracked&amp;nbsp; this issue&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Amit&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 May 2014 12:09:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085674#M1506597</guid>
      <dc:creator>shivhare</dc:creator>
      <dc:date>2014-05-07T12:09:33Z</dc:date>
    </item>
    <item>
      <title>Re: Remove charset=utf-8 from HTTP POST</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085675#M1506598</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I had a similar problem and could resolve it by using APPEND_DATA instead of APPEND_CDATA. Likewise, SET_DATA instead of SET_CDATA might solve the issue for you. The data has to be provided as binary data then.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Stefan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 12:52:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085675#M1506598</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2014-08-21T12:52:55Z</dc:date>
    </item>
    <item>
      <title>Re: Remove charset=utf-8 from HTTP POST</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085676#M1506599</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND_DATA works fine for me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I use for the String-To-XString-Conversion the following FM:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 12px; color: #333333; background: #ffffff;"&gt;&lt;EM&gt;CALL FUNCTION 'SCMS_STRING_TO_XSTRING'&lt;/EM&gt;&lt;/P&gt;&lt;P style="font-size: 12px; color: #333333; background: #ffffff;"&gt;&lt;EM&gt;EXPORTING&lt;/EM&gt;&lt;/P&gt;&lt;P style="font-size: 12px; color: #333333; background: #ffffff;"&gt;&lt;EM&gt;text = output " variable type string&lt;/EM&gt;&lt;/P&gt;&lt;P style="font-size: 12px; color: #333333; background: #ffffff;"&gt;&lt;EM&gt;IMPORTING&lt;/EM&gt;&lt;/P&gt;&lt;P style="font-size: 12px; color: #333333; background: #ffffff;"&gt;&lt;EM&gt;buffer = outputx. " variable type &lt;/EM&gt;&lt;EM&gt;xstring&lt;/EM&gt;&lt;/P&gt;&lt;P style="font-size: 12px; color: #333333; background: #ffffff;"&gt;&lt;/P&gt;&lt;P style="font-size: 12px; color: #333333; background: #ffffff;"&gt;Regards,&lt;/P&gt;&lt;P style="font-size: 12px; color: #333333; background: #ffffff;"&gt;&lt;/P&gt;&lt;P style="font-size: 12px; color: #333333; background: #ffffff;"&gt;&lt;/P&gt;&lt;P style="font-size: 12px; color: #333333; background: #ffffff;"&gt;Matthias&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Mar 2016 09:54:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085676#M1506599</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2016-03-07T09:54:51Z</dc:date>
    </item>
    <item>
      <title>Re: Remove charset=utf-8 from HTTP POST</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085677#M1506600</link>
      <description>&lt;P&gt;Hi guys,&lt;/P&gt;&lt;P&gt;following Mattias and Stefan comments, it works for me too - using SET_DATA( ) instead of SET_CDATA( ), converting string to xstring beforehand.&lt;/P&gt;&lt;P&gt;Thanks for sharing!&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Ivaylo&lt;/P&gt;</description>
      <pubDate>Thu, 16 Nov 2023 14:42:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/7085677#M1506600</guid>
      <dc:creator>Ivaylo</dc:creator>
      <dc:date>2023-11-16T14:42:14Z</dc:date>
    </item>
    <item>
      <title>Re: Remove charset=utf-8 from HTTP POST</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/13962273#M2038119</link>
      <description>&lt;P&gt;To avoid charset=UTF-8&lt;BR /&gt;&lt;BR /&gt;I am referencing variables from your code for you to better understand, just add below code&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;CALL METHOD http_client-&amp;gt;request-&amp;gt;suppress_charset ( supress = abap_true ).&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Ajinkya Chothave&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Dec 2024 17:31:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/remove-charset-utf-8-from-http-post/m-p/13962273#M2038119</guid>
      <dc:creator>ajinkyachothave-1</dc:creator>
      <dc:date>2024-12-12T17:31:54Z</dc:date>
    </item>
  </channel>
</rss>

