Hi All I am using this code
FUNCTION fnEnc(txtToEncrypt) postUrl = "http://fastdev1.usask.ca:81/encdec.asmx/fnEnc" Set xmlhttp = server.Createobject("MSXML2.XMLHTTP") xmlhttp.Open "POST",postUrl,false xmlhttp.setRequestHeader "Content-Type","application/x-www-form-urlencoded" xmlhttp.send txtToEncrypt fnEnc = xmlhttp.responseText END FUNCTION
and when calledlike this
DataToSendDec = "strValue=" & Request.Querystring(key)
enc=fnEnc(DataToSendDec)
Response.Write "Encrypted__:" & key & ": " & enc & "<BR>"
I get
Encrypted__:D: szQFw5zM8b767Qh6gSCb0A==
notice how there is a space between D: and sz...
so I figure there is some ASC in there i cant see so using Server.HTMLEncode
Response.Write "Encrypted__:" & key & ": " & Server.HTMLEncode(enc) & "<BR>"
I now get:
Encrypted__:D: <?xml version="1.0" encoding="utf-8"?> <string xmlns="http://tempuri.org/">szQFw5zM8b767Qh6gSCb0A==</string>
how do i pull just the string out of that xmlhttp.responseText