I am using spring, spring security, hibernate. Got a jsp page where i am trying to upload a file, and backend a i have a controller to capture and store the file uploaded. I am using tomcat. I am using spring security for login authentication. Getting the following error when i upload the file
HTTP Status 405 – Request method ‘POST’ not supported
Any ideas?
I am using spring, spring security, hibernate. Got a jsp page where i am
Share
You will need to ensure your request handler is able to accept a POST. You can also configure Spring to use a MultipartResolver to aid you in getting your request parts.
Configuration of MultiPartResolver
Here is the request mapping:
Note, that sometimes this will not work with Spring Security. You can look at my blog post here on using multipartrequestresolvers with spring security for help:
http://www.adamweigold.com/2012/01/using-multpartrequestresolvers-with.html