我正在尝试使用 jquery.ajax 调用我的网络服务。
jQuery.support.cors = true;
$.ajax({
type: 'POST',
url: wsUrl,
contentType: "text/xml; charset=utf-8",
dataType: "xml",
cache: false,
crossDomain: true,
data: soapRequest,
success: reqSuccess,
error: reqError
});
我得到“拒绝访问”-错误和状态/readyState 0。
如果我使用 SoapUI 向我的 web 服务发出请求,它工作得很好。