$(function() {
$('#form-data').on('submit', function(e){
e.preventDefault();
var form = $(this);
formData = new FormData(form.get(0));
var url = 'upload.php';
$.ajax({
url: url,
type: 'POST',
data: formData,
contentType: false,
cache: false,
processData:false,
success: function(response) {
console.log(response)
}
});
})
});
$(function() {
$('#writeAppointment').on('submit', function(e){
e.preventDefault();
var form = $(this);
formData = new FormData(form.get(0));
var url = 'multisend.php';
$.ajax({
url: url,
type: 'POST',
data: formData ,
contentType: false,
cache: false,
processData:false,
success: function(response) {
console.log(response)
}
});
})
});