A
A
Andrew2017-08-04 08:50:58
JavaScript
Andrew, 2017-08-04 08:50:58

How to send Post multipart/form-data with two forms, the first is a json object and the second is a binary file?

I don’t understand how you can send two forms at once, you can give an example, it would be good for js or a postman. this is how the http request should be https://pastebin.com/cfGX4ji8
and how to make content-disposition different for different forms, as above in the example

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Stalker_RED, 2017-08-04
@undefined_title

How can I submit two forms at once?
No, just take turns.
and why and how in the header content-disposition you can set several values ​​\u200b\u200bas above in the example
Here is https://developer.mozilla.org/ru/docs/Web/HTTP/Hea...
Perhaps you are confusing the concept of a form (form) and a field (field).
Here is an example of submitting a form with files via XHR: https://developer.mozilla.org/en/docs/Web/API/Form...
And the JSON object can be converted to a string and sent.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question