【发布时间】:2012-02-12 00:21:20
【问题描述】:
我想发送一个数组作为 Ajax 请求:
info[0] = 'hi';
info[1] = 'hello';
$.ajax({
type: "POST",
url: "index.php",
success: function(msg){
$('.answer').html(msg);
}
});
我该怎么做?
【问题讨论】:
-
type: 'POST', url: '/url/action/', data: { param1: 1, id: "text" }, dataType: 'text',