使用邮递员在 asp.net 核心中上传文件时未从 header 获取边界
Not getting BOUNDARY from the header while using postman to upload a file in asp.net core
我正在尝试使用邮递员发送文件,以使用 asp.net 核心将其上传到网络服务。
现在,postman 生成的片段在请求后看起来像这样
在我的控制器方法中
request.ContentType.Value 为空
我做错了什么?
删除您手动添加的 content-type header 并改为 POST 请求中的 select form-data > Body
我正在尝试使用邮递员发送文件,以使用 asp.net 核心将其上传到网络服务。
现在,postman 生成的片段在请求后看起来像这样
在我的控制器方法中
request.ContentType.Value 为空
我做错了什么?
删除您手动添加的 content-type header 并改为 POST 请求中的 select form-data > Body