How to store files with meta data in LoopBack?

前端 未结 7 1756
别跟我提以往
别跟我提以往 2020-11-28 03:05

What I want to do: Have an html form, with a file input inside. When a file is chosen, the file input should upload the file, and get a file id, so when the form is submitte

7条回答
  •  天命终不由人
    2020-11-28 03:38

    For anyone else having that problem with loopback 3 and Postman that on POST, the connection hangs (or returns ERR_EMPTY_RESPONSE) (seen in some comments here)... The problem in this scenario is, that Postman uses as Content-Type "application/x-www-form-urlencoded"!

    Please remove that header and add "Accept" = "multipart/form-data". I've already filed a bug at loopback for this behavior

提交回复
热议问题