我正在使用以下代码使用 jquery 调用外部 Web 服务。在Chrome
中,我收到此“500 内部服务器错误”,在 Firefox 中,它显示'0'
我无法弄清楚问题所在。这是我的完整代码..
<script type="text/javascript" src="js/jquery-1.3.1.min.js"></script>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jQuery/1.2.6/jQuery.min.js">
</script>
<script type="text/javascript">
$(document).ready(function () {
$("#btnCall").click(function (event) {
$.ajax({
type: "POST",
url: "www.google.com",
data: "{'ESS123', 'aaaaaa', '', 'abc@hotmail.com', '23424234', '', 0, 100, 1000007, 1, '', 12, '','','', '2013', '', 1, 1000006, 1000033, 100, 1000012, 1000012, 1000001, 1000001, 100, 'caff4eb4fbd6273e37e8a325e19f0991'}",
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function (msg) {
alert('s');
},
error: AjaxFailed
});
});
});
function AjaxSucceeded(result) {
alert('s');
//alert(result.d);
}
function AjaxFailed(result) {
alert(result.status + ' ' + result.statusText);
}
</script>
<body>
<input type="button" value="Submit" id="btnCall" />
</body>