由於某種原因,我的JavaScript代碼中的innerHTML正在鎖定其他JavaScript函數,而我也不知道爲什麼......這是鎖定其他人的JavaScript。JavaScript innerHTML鎖定其他javascripts
var city = $('#search-bar').val();
$.ajax({
url: '/Index/getWeatherSearch',
data: { city: city },
//async: false,
error: function (resp) {
alert("Error");
},
complete: function (resp) {
var div = document.getElementById('rb-grid');
div.innerHTML = resp.responseText + div.innerHTML;
}
});
'鎖'意味着什麼? – epascarello
鎖定?你的意思是阻止其他jquery函數的一些錯誤? –
可能重複:http://stackoverflow.com/questions/22694969/javascript-stop-working-after-ajax-call?rq=1 –