serverxmlhttp

convert utf-8 to iso-8859-1 in classic asp

浪尽此生 提交于 2019-11-26 11:33:06
问题 My site now works purely in UTF-8, but in order to send an SMS using serverXMLHTTP I need to convert my message from UTF-8 til ISO-8859-1 before sending it. The situation is parallel to this: a.asp: <html><head> <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\"> </head><body> <form method=\"post\" action=\"b.asp\"> <input type text name=\"message\" value=\"æøå and ÆØÅ\"><br> <input type=submit> </body> and then b.asp <html><head> <meta http-equiv=\"Content-Type\" content=

How can I send an HTTP POST request to a server from Excel using VBA?

╄→尐↘猪︶ㄣ 提交于 2019-11-25 23:33:29
问题 What VBA code is required to perform an HTTP POST from an Excel spreadsheet? 回答1: Set objHTTP = CreateObject("MSXML2.ServerXMLHTTP") URL = "http://www.somedomain.com" objHTTP.Open "POST", URL, False objHTTP.setRequestHeader "User-Agent", "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)" objHTTP.send("") Alternatively, for greater control over the HTTP request you can use WinHttp.WinHttpRequest.5.1 in place of MSXML2.ServerXMLHTTP. 回答2: If you need it to work on both Mac and Windows, you