Valid = false;
//取得商户号
string MerchantID = Request.Form["MerchantID"];
string Amount = Request.Form["PaidAmount"];
MSXML2.XMLHTTP Obj = new MSXML2.XMLHTTPClass();
Obj.open("POST","http://www.WestPay.com.cn/pay/ISPN.asp",false,null,null);
Obj.setRequestHeader("Content-type","application/x-www-form-urlencoded");
Obj.send(Request.Form);错在最后一句,说是“The parameter is incorrect. ”那个send()方法的参数是object类型的,可是就算是使用一个object对象也还是同样的问题。郁闷了。
恳请高手出来相助,小弟不胜感激。
//取得商户号
string MerchantID = Request.Form["MerchantID"];
string Amount = Request.Form["PaidAmount"];
MSXML2.XMLHTTP Obj = new MSXML2.XMLHTTPClass();
Obj.open("POST","http://www.WestPay.com.cn/pay/ISPN.asp",false,null,null);
Obj.setRequestHeader("Content-type","application/x-www-form-urlencoded");
Obj.send(Request.Form);错在最后一句,说是“The parameter is incorrect. ”那个send()方法的参数是object类型的,可是就算是使用一个object对象也还是同样的问题。郁闷了。
恳请高手出来相助,小弟不胜感激。
{ var xmlDoc = new ActiveXObject("MSXML.DOMDocument");
xmlDoc.async = false;
//build your string here
strXML = "<?xml version=\"1.0\"?><root>" + strXML + "</root>"; var ObjHttp = new ActiveXObject("Microsoft.XMLHTTP");
if(xmlDoc.loadXML(strXML))
{
ObjHttp.Open("POST",strURL,false);
ObjHttp.Send(xmlDoc);
return ObjHttp.responseXML.xml;//you can get the resposne text instead.
}
else
{
return "FALSE";
}
}