Answer the question
In order to leave comments, you need to log in
Why empty request.FILE on preventDefault?
there is a form with a field for entering text and adding a file, the whole thing goes through ajax
when I add preventDefault in the script I get an empty MultiValueDict
when I remove preventDefault the file is present, but it redirects to the response json page
how to do it correctly so that you can send the file and the server does not display json view response, but left it on the same page?
code https://gitlab.com/axce1/talk
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question