다음은 스크립트입니다. 그것은 다른 모든 브라우저에서 잘 작동하므로 캐시 문제이지만 실제로는 아니라고 생각했습니다. 나는 몇 시간 동안 내 머리를 부딪 치고 있었고 아무것도 작동하지 않았다.Ajax가 IE에로드되지 않습니다
$.ajaxSetup({
cache: false
});
$("#send").live('click', function() {
console.log("AAAAA");
$("#loader").show();
$form = $('#reservationForm');
$inputs = $form.find('input[name^="entry"]'),
serializedData = $('#reservationForm :input[name^="entry"]').serialize();
console.log(serializedData);
serializedData += "&pageNumber=0&backupCache=1&submit=Submit";
// fire off the request to /form.php
$.ajax({
url: "https://docs.google.com/spreadsheet/formResponse?formkey=d",
// url: "https://docs.google.com/spreadsheet/formResponse?formkey=d;ifq",
type: "post",
data: serializedData,
// callback handler that will be called on success
success: function (response, textStatus, jqXHR) {
// log a message to the console
console.log("Hooray, it worked!");
$("#loader").hide();
document.getElementById('error<?php echo"$uname";?>').innerHTML = error;
$("#success").fadeIn();
setTimeout(function() {
$("#success").fadeOut();
}, 5000);
},
// callback handler that will be called on error
error: function (jqXHR, textStatus, errorThrown) {
// log the error to the console
console.log("The following error occured: " + textStatus, errorThrown);
alert('Due to an unknown error, your form was not submitted, please resubmit it or try later.');
},
// callback handler that will be called on completion
// which means, either on success or error
complete: function() {
// enable the inputs
$inputs.removeAttr("disabled");
}
});
// prevent default posting of form
event.preventDefault();
});
내가 읽을 수있는 자바 스크립트를 만들어 – GottZ
코드를 내가 그것을 편집하는 방법을 시도 고려할 수있다 "missplaced 삭제했습니다 – GottZ
당신은 – mikipero