<分区>
我像那样从 PHP 返回数据。
$return['fillable'] = [
'field_one',
'field_two',
'field_three',
'field_four',
'field_five',
];
$json = json_encode($return);
return $json;
现在在我的 ajax 响应中,我想循环填充数组。
$.ajax({
'type': "GET",
'global': false,
'dataType': 'json',
'url': "/commission-process/"+$('#token').val(),
'data': {'ajax': true},
'success': function (data) {
// how to loop my return array data.
}
});
我的问题是,我想循环打印这样的可填充数组。
field_one
field_two
field_three
field_four
field_five
谢谢。