为了账号安全,请及时绑定邮箱和手机立即绑定

上传显示405,不支持post?

29148 [http-nio-8080-exec-2] DEBUG org.springframework.web.servlet.DispatcherServlet  - Successfully completed request

57836 [http-nio-8080-exec-5] DEBUG org.springframework.web.servlet.DispatcherServlet  - DispatcherServlet with name 'mvc-dispatcher' processing POST request for [/spring-mvc-study0605/courses/upload]

57836 [http-nio-8080-exec-5] DEBUG org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping  - Looking up handler method for path /courses/upload

57844 [http-nio-8080-exec-5] DEBUG org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver  - Resolving exception from handler [null]: org.springframework.web.HttpRequestMethodNotSupportedException: Request method 'POST' not supported

57844 [http-nio-8080-exec-5] DEBUG org.springframework.web.servlet.mvc.annotation.ResponseStatusExceptionResolver  - Resolving exception from handler [null]: org.springframework.web.HttpRequestMethodNotSupportedException: Request method 'POST' not supported

57844 [http-nio-8080-exec-5] DEBUG org.springframework.web.servlet.mvc.support.DefaultHandlerExceptionResolver  - Resolving exception from handler [null]: org.springframework.web.HttpRequestMethodNotSupportedException: Request method 'POST' not supported

57844 [http-nio-8080-exec-5] WARN  org.springframework.web.servlet.PageNotFound  - Request method 'POST' not supported



正在回答

2 回答

注意下,课程的文件里,file没有指明路径,我估计很多人会遇到这个404错误

1 回复 有任何疑惑可以回复我~

这个问题搞定了,加上common-io依赖以后,问题变成了500,然后加了上传配置后就成功了。

0 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

上传显示405,不支持post?

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信