I have a form with a multiple select box. When I select more than one option and send the form via an ajax cal to a php file, only the last option will be saved. Why is that so?
This is the AJAX call:
var daten = $('#formulargesamt').serialize(); console.log(daten); $.ajax({ url: "/ajax/neukundenanlage/get_formular.php", data: daten, method: "POST", });
n the console.log
prompt all data is there (as a string). However in the PHP file it is an array with only the last selected option.
Does anyone have a idea how I can fix this?
Thanks!