I have this Ajax to send multiple images:
$('#btn').on("click", function () {
var formData = new FormData($("#form1")[0]);
var path = "php/upload/adm_prodpictures.php";
$.ajax({
url: path,
type: "POST",
data: formData,
contentType: false,
processData: false,
success: function (stuff) {
$("#resp").html(stuff);
}
});
});
});
I have to process this images in the php-side and insert them in a mysql db. So to insert in the proper way, I have to send a javascript variable. How can I append this variable to the 'bundle' that is sent?