警告: No mapping found for HTTP request with URI的解决方案
2015-12-29 16:39
721 查看
使用springMVC,访问action时报错:
2015-12-29 16:37:11 org.springframework.web.servlet.DispatcherServlet noHandlerFound
警告: No mapping found for HTTP request with URI [/springmvc/index.jsp] in DispatcherServlet with name 'mvc-dispatcher'
后来排查是这里的问题:
在web.xml中
修改为:
2015-12-29 16:37:11 org.springframework.web.servlet.DispatcherServlet noHandlerFound
警告: No mapping found for HTTP request with URI [/springmvc/index.jsp] in DispatcherServlet with name 'mvc-dispatcher'
后来排查是这里的问题:
在web.xml中
<servlet> <servlet-name>mvc-dispatcher</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <init-param> <param-name>contextConfigLocation</param-name> <param-value>classpath:spring-mvc.xml</param-value> </init-param> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>mvc-dispatcher</servlet-name> <strong><url-pattern>/*</url-pattern></span></strong> </servlet-mapping>
修改为:
<servlet> <servlet-name>mvc-dispatcher</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <init-param> <param-name>contextConfigLocation</param-name> <param-value>classpath:spring-mvc.xml</param-value> </init-param> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>mvc-dispatcher</servlet-name> <strong><url-pattern>*.action</url-pattern></span></strong> </servlet-mapping>
相关文章推荐
- Oracle Containers for J2EE远程安全漏洞(CVE-2014-0413)
- 杀毒软件 Dr.Web Anti-virus for Windows Vista 4.44.0 Beta
- C#中循环语句:while、for、foreach的使用
- for 提取文本整行内容的方法
- dos命令for用法详解
- for命令的一些bug分析
- 批处理 FOR参数/F之tokens详解
- Lua中数字for循环实例
- 杀毒软件 Dr.Web Anti-virus for Windows Vista 4.44.0 Beta
- Nero v3.0.0.0 for LINUX 版本 下载
- for语句中的几种分隔符形式小结
- Shell中的for和while循环详细总结
- MySQL4 File ‘c:\mysql\share\charsets\?.conf’ not found (Errcode: 22)的解决方法
- 非常好的for 教程, 当时我就是看这个学习for 的第1/2页
- mysql Access denied for user ‘root’@’localhost’ (using password: YES)解决方法
- 批处理FOR 中的Delims和Tokens总结
- for 语句从入门到精通
- 最新的 for Vista RTM 驱动程序
- JavaScript中for循环的使用详解
- asp中for循环的使用方法