fetch - Missing boundary in multipart/form-data POST

前端 未结 6 1565
不知归路
不知归路 2020-11-27 14:45

thanks for stopping by.

I want to send a new FormData() as the body of a POST request using the fetch api

the operatio

6条回答
  •  情歌与酒
    2020-11-27 15:12

    The solution to the problem is to explicitly set Content-Type to undefined so that your browser or whatever client you're using can set it and add that boundary value in there for you. Disappointing but true.

提交回复
热议问题