请帮我为我的应用程序修复这个脚本,我正在尝试让链选择工作。该脚本基本上从下拉列表中检查选定的下拉值并在数据库中搜索该值
JS:
<Script type="text/javascript">
$("#propinsi_id").change(function () {
var propinsi_id = {
propinsi_id: $("#propinsi_id").val()
};
$.Ajax({
type: "POST",
url: "<?php echo SITE_URL('Repair/select_fault')?>",
Data: propinsi_id,
success: function (msg) {
$('#city').html(msg);
}
});
});
</Script>
错误:
I caught this error
Uncaught TypeError: Object
function (selector, context) {
//The jQuery object is actually just the init constructor 'enhanced'
return new jQuery.fn.init(selector, context, rootjQuery);
}
has no method 'Ajax'