项目是使用SpringMVC

(1)在浏览器中访问,后台总报错:

No mapping found for HTTP request with URI [] in DispatcherServlet with name 'appServlet'

查了好半天,才发现是Controller没有扫描到

<mvc:annotation-driven  />
<!-- 扫描Controller -->
<context:component-scan base-package="com.winner.controller"/>

注意,不是说Controller上写了个@Controller注解就完事了,Spring没扫描到的话这个注解毛用都没有!!!

这么简单的问题遇到好几次,我也是醉了......

No mapping found for HTTP request with URI [] in DispatcherServlet with name 'appServlet'的更多相关文章

  1. Spring Boot, Java Config - No mapping found for HTTP request with URI [/…] in DispatcherServlet with name 'dispatcherServlet'

    Spring Boot 启用应用: error: No mapping found for HTTP request with URI [/…] in DispatcherServlet with n ...

  2. 【Java/Spring】Spring的配置问题,IDEA报错“No mapping found for HTTP request with URI […] in DispatcherServlet”

    从SVN上拷贝下JavaWeb项目,Spring框架的配置文件需要修改.部署好Tomcat后,启动服务,可以进入Web项目主页,但是访问其他URL时直接跳转到404,IDEA报错“No mapping ...

  3. No mapping found for HTTP request with URI [/***] in DispatcherServlet with name 'dispatcherServlet'

    相信不少Springboot初学者和我一样,都遇到上边这个提示,明明路径都是对的,但就是找不到对于的页面而404了,这也困扰我很长一段时间,我也是不得其解,百度上也鲜有合理回答,因为以前使用的时候,明 ...

  4. org.springframework.web.servlet.PageNotFound - No mapping found for HTTP request with URI

    在重启项目中会遇到[org.springframework.web.servlet.PageNotFound] - No mapping found for HTTP request with URI ...

  5. spring访问静态资源出错,No mapping found for HTTP request with URI xxx/resources/js/jquery.min.js...

    问题:spring访问静态资源出错,No mapping found for HTTP request with URI xxx/resources/js/jquery.min.js... web.x ...

  6. springmvc No mapping found for HTTP request with URI in Dispatc

    springmvc No mapping found for HTTP request with URI in Dispatc 博客分类: Java Web springmvcspring MVCNo ...

  7. SpringMvc出现No mapping found for HTTP request with URI的终极解决办法

    No mapping found for HTTP request with URI 出现这个问题的原因是在web.xml中配置错了,如: <servlet> <servlet-na ...

  8. 问题 “No mapping found for HTTP request with URI [/rbiz4/uploadFile.html]” 的解决

    从以前的SpringMVC项目简化一下做个例子,结果出现了下面的错误: No mapping found for HTTP request with URI [/rbiz4/uploadFile.ht ...

  9. 相对路径获取项目文件 及报错 No mapping found for HTTP request with URI XXX in DispatcherServlet with name ‘springmvc’解决方法

    首先一点,WebRoot目录下的文件是都可以通过浏览器输入路径,直接读取到的 例如这样: 而WebRoot下面WEB-INF是无法浏览器输入路径直接读取的. 因为是受保护的. 如果jsp读取一个图片的 ...

随机推荐

  1. MongoBD解决没有自动增长ID 的问题

    Sequence Numbers:序列号传统的数据库中,通常用一个递增的序列来提供主键,在 MongoDB中用 ObjectId 的来代替,我们可以通过如下的函数来获取主键 function coun ...

  2. C# 取整

    double a = 1.1478; Math.Celling(a): 向上取整,结果为2 Math.Float(a); 向下取整,结果为1 Math.Round(a,2);  保留两位小数的奇进偶舍 ...

  3. php读取3389脚本

    <?php $regkey = 'HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server\Wds\rdpwd\Td ...

  4. Linux环境下实现哲学家就餐问题(2)

    #include <stdio.h> #include <pthread.h> #include <stdlib.h> #include <string.h& ...

  5. iOS - AVAudioPlayer 音频播放

    前言 NS_CLASS_AVAILABLE(10_7, 2_2) @interface AVAudioPlayer : NSObject @available(iOS 2.2, *) public c ...

  6. HashTable的典型用法以及参考实例

    Get-ADComputer -Identity "cnhzpd-f7sc83x" | select -property @{name="computername&quo ...

  7. UITextField里面的 placeholder颜色和字体

    //  placeholder 颜色 [field setValue:[UIColor redColor] forKeyPath:@"_placeholderLabel.textColor& ...

  8. 20145317彭垚 java课程总结

    课程总结 每周读书笔记链接汇总 第一周http://www.cnblogs.com/5317p/p/5248481.html 第二周http://www.cnblogs.com/5317p/p/527 ...

  9. Types of compression algorithms

    http://www.html5rocks.com/en/tutorials/speed/img-compression/ Types of compression algorithms There ...

  10. 关于Java的File.separator

    在Windows下的路径分隔符和Linux下的路径分隔符是不一样的,当直接使用绝对路径时,跨平台会暴出“No such file or diretory”的异常. 比如说要在temp目录下建立一个te ...