enter image description here So, this is the payload and I am trying send form data along with the file but using form.serialize is formatting the csv file as well, any suggestion on how it can be sent without affecting the file?
Asked
Active
Viewed 15 times
0
-
you need to use `multipart/form-data` – Scary Wombat Oct 13 '21 at 01:04
-
tries, but then it changes the request format, – AtikiniAmal Oct 13 '21 at 01:05
-
Have a look at https://stackoverflow.com/questions/10899384/uploading-both-data-and-files-in-one-form-using-ajax – Scary Wombat Oct 13 '21 at 01:06
-
great, thanks, will try it out, and since looks like it is duplicate to that, will delet this one – AtikiniAmal Oct 13 '21 at 01:10
-
Yes a duplicate - see the accepted answer (it is a multipart/form-data form) – Scary Wombat Oct 13 '21 at 01:11