spring mvc老是接收不到前台传递来的参数,搞了半天才知道spring mvc对PUT方法支持不好,难受!在web.xml文件中加入下面的过滤器应该可以解决:
<filter> <filter-name>HttpMethodFilter</filter-name> <filter-class>org.springframework.web.filter.HttpPutFormContentFilter</filter-class> </filter> <filter-mapping> <filter-name>HttpMethodFilter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping>
https://blog.csdn.net/lovequanquqn/article/details/84774914
原文地址:https://www.cnblogs.com/achengmu/p/11062073.html
时间: 2024-10-10 19:26:44