I'm writing a survey and I have a form with lot of inputs. The first ten are for personal data like and images, the others, in variable number, will be the questions of my survey.
I want the user to upload multiple images, but I'd like he could even remove some images right before. I know I can't remove files from the file object, so I had this idea: if I could upload the image right in the moment the user chooses (the on input event, or maybe on load) without sending the form I will store the image in a temporary folder (and with a js function I'll handle the file inputs to replace with a new one etc.).
So, finally, the question is: is there a way to upload a single input, maybe with ajax, without sending all inputs?
form.submit()will submit the entire form. Perhaps adding your HTML markup would be a good idea?