开发者

Relitve path for MSXML2.ServerXMLHTTP.6.0 not working

I have this code which works but I need to stop using http in the string as it sometimes is on a https servers. Hence my wish to change it to a relative path e.g. Url = "../../path/to/file.asp" but when make the change to this开发者_StackOverflow中文版 code we get this error.

msxml6.dll error '80072ee6' 

System error: -2147012890.

I am sure I missing something simple. Anybody got any ideas?

Working code fragmant

Url = "http://" & Request.ServerVariables("SERVER_NAME") & "/path/to/file.asp"

Set HttpReq = Server.CreateObject("MSXML2.ServerXMLHTTP.6.0")

With HttpReq
 .Open "POST", Url, false
 .setTimeouts 30000, 60000, 30000, 120000
End With

HttpReq.Send (RequestXml)


Yes its been a while I think the fix was to not state the "http://" and let the sever work it out.

e.g. Url = Request.ServerVariables("SERVER_NAME") & "/path/to/file.asp"

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜