SSM-----springMVC No mapping found for HTTP request with URI的问题
来源:互联网 发布:淘宝游戏王正版 编辑:程序博客网 时间:2024/06/06 09:45
No mapping found for HTTP request with URI
出现这个问题的原因是在web.xml中配置错了,如:
<servlet> <servlet-name>springMVCDispatcherServlet</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <init-param> <param-name>contextConfigLocation</param-name> <param-value>/WEB-INF/springMVC-servlet.xml</param-value> </init-param> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>springMVCDispatcherServlet</servlet-name> <url-pattern>/*</url-pattern> </servlet-mapping>
当你在control中返回一个路径的时候,它又把路径(/view/index.jsp)当作一个请求被dispatcherServlet所拦截。所以会抛出异常。
解决的办法
第一个方法
即使让dispatcherServlet的拦截加上后缀如:*.do;这样以jsp后缀的就不会别拦截了。
第二个方法
在spring-servlet.xml中加入:
<mvc:default-servlet-handler/>
阅读全文
0 0
- SSM-----springMVC No mapping found for HTTP request with URI的问题
- mark springmvc [No mapping found for HTTP request with URI]
- springMVC No mapping found for HTTP request with URI
- springMVC No mapping found for HTTP request with URI
- springMVC No mapping found for HTTP request with URI
- springMVC No mapping found for HTTP request with URI
- springMVC--关于no mapping found for http request with uri
- springMVC--关于no mapping found for http request with uri .......
- springMVC No mapping found for HTTP request with URI
- springMVC No mapping found for HTTP request with URI
- springmvc 出现No mapping found for HTTP request with URI
- No mapping found for HTTP request with URI问题
- 不一样的No mapping found for HTTP request with URI
- 深恶痛绝的No mapping found for HTTP request with URI
- No mapping found for HTTP request with URI [/ss1/] in DispatcherServlet with (SSM)
- maven+spring 遇到No mapping found for HTTP request with URI的问题
- springMVC报WARNING: No mapping found for HTTP request with URI [/springMVC/hello] in DispatcherServle
- 警告: No mapping found for HTTP request with URI [/Springmvc/test] in DispatcherServlet with dispatche
- java n*n的二维数组转置,不开辟新的空间
- Hadoop DataNode 无法连接到主机NameNode
- maven配置(阿里云)
- sklearn学习——SVM
- Android --- 常用的系统服务(二)
- SSM-----springMVC No mapping found for HTTP request with URI的问题
- mmap内存映射
- WMware中linux系统无wlan0网卡的解决方法
- 文章标题
- 百度地图接口
- HDOJ 1406 完数
- transform、transition、animation区别
- JSP中请求转发何请求重定向的区别
- 1!+2!+...+n!