php - How to pass formData and another object data together through ajax
我想大声告诉你
我想大声告诉你 2017-05-16 13:12:31
0
1
523

How to pass formData and another object data together through ajax

data:formData+"&type="+$("#1").val(), doesn't this work?

我想大声告诉你
我想大声告诉你

reply all(1)
左手右手慢动作
var formData = new FormData();    
formData.append('xxx', xxxxxx);
formData.append('type', $("#1").val());
...

$.ajax({
  url: '/test',
  data: formData,
  processData: false,
  contentType: false,
  type: 'POST',
  success: function(data){
    alert(data);
  }
});
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template