[quoted text, click to view] <jenschindler@gmail.com> wrote in message
news:1130856153.983416.272490@g49g2000cwa.googlegroups.com...
> Thanks for your reply!
ps: To -read- this post well, your NNTP reader, needs to support UTF-8 if it
does not, it might be a *unix or linux ASCII reader, which sucks :)
[quoted text, click to view] > I tried ServerXMLHTTP (using your example code), but the form doesn't
> post.
>
> Here is my code:
>
> set HTTPObj = Server.CreateObject("Msxml2.ServerXMLHTTP.3.0")
> HTTPObj.Open "POST", "myURL", False
> HTTPObj.setRequestHeader "charset", "UTF-8"
> HTTPObj.setRequestHeader "Content-Type",
> "application/x-www-form-urlencoded"
> HTTPObj.Send strQuery
> set HTTPObj = nothing
>
> Got any ideas?
It really works...
name your page 'fetch.asp'
'code page=utf-8
' safe these pages as utf-8 in notepad for instance!
<% @codepage=65001 %>
<%
Dim log, myfile
Set Log = CreateObject("Scripting.FileSystemObject")
Set myfile = log.OpenTextFile("c:\\temp\\somelog.txt", 8, True,-1)
myfile.WriteLine(Request.Form("var1"))
myfile.WriteLine(Request.QueryString("page"))
myfile.Close
%>
<html xmlns="
http://www.w3.org/1999/xhtml"> <head><title>test</title></head>
<body>
<p>Success</p>
</body>
</html>
name this as postit.asp (ps: Server.CreateObject is legacy stuff with some
overhead, just use CreateObject)
<% @codepage=65001 %>
<%
set HTTPObj = CreateObject("Msxml2.ServerXMLHTTP.4.0")
HTTPObj.Open "POST", "http://localhost/fetch.asp?page=welcome", False
HTTPObj.setRequestHeader "charset", "UTF-8"
HTTPObj.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
HTTPObj.Send "var1=" + Server.UrlEncode("345+_23498234LDSF@@#1!@#$%^&()Ðкак
дела?")
%>
Result
c:\temp\somelog.txt is unicode, completely and reads exactly the value as
posted in var1...
[quoted text, click to view] > TIA!
Be my guest...
--
compatible web farm Session replacement for Asp and Asp.Net
http://www.nieropwebconsult.nl/asp_session_manager.htm