jquery如何通过ajax请求获取后台数据显示在

2025-04-08 08:17:09
推荐回答(1个)
回答1:

	$.ajax({
type: "GET",
url: "test.json",
data: {
test: $("#test").val(),

},
dataType: "json",
success: function(data) {

$('#resText').empty(); //清空resText里面的所有内容

var html = '';
//你的逻辑

$('#resText').html(html);
}
});