问题?Invalid content was found starting with element 'mvc:exclude-mapping'.

这是springmvc中显著的错误,在配置拦截器的时候,会用到不拦截某一些请求

如:

  1. < mvc:interceptors>
  2. <span style="white-space:pre">    </span>< mvc:interceptor>
  3. <span style="white-space:pre">        </span>< mvc:mapping path=”/**”/>//过滤全部请求
  4. <span style="white-space:pre">        </span>< mvc:exclude-mapping path=”/hello.html”/> //除了hello这个请求
  5. <span style="white-space:pre">        </span>< bean class=”net.spring.interceptor.TestInterceptor” />
  6. <span style="white-space:pre">    </span></mvc:interceptor>
  7. </mvc:interceptors>


< mvc:exclude-mapping path=”/hello.html”/>
//除了hello这个请求

这条语句就会出问题?会报以上的错误,Invalid content was found starting with element 'mvc:exclude-mapping'.原因是:mvc:exclude-mapping
标签不被spring-mvc-3.0.xsd支持,该配置在spring-mvc-3.2.xsd中支持。

把http://www.springframework.org/schema/mvc/spring-mvc-3.0.xsd改成http://www.springframework.org/schema/mvc/spring-mvc-3.2.xsd

Invalid content was found starting with element 'mvc:exclude-mapping'.的更多相关文章

  1. 【解决方案】cvc-complex-type.2.4.a: Invalid content was found starting with element 'init-param'. One of '{"http://java.sun.com/xml/ns/javaee":run-as, "http://java.sun.com/xml/ns/javaee":security-role-r

    [JAVA错误] cvc-complex-type.2.4.a: Invalid content was found starting with element 'init-param'. One o ...

  2. web.xml文件报错:cvc-complex-type.2.4.a: Invalid content was found starting with element 'init-param'.

    <?xml version="1.0" encoding="UTF-8"?> <web-app version="3.0" ...

  3. cvc-complex-type.2.4.a: Invalid content was found starting with element

    在写xml的时候又一次总是报cvc-complex-type.2.4.a: Invalid content was found starting with element 错误,还出现小红叉,在网上找 ...

  4. Invalid content was found starting with element 'taglib'”

    今天在使用struts-menu制作菜单,在web.xml中写入 <taglib>      <taglib-uri>/WEB-INF/struts-menu.tld</ ...

  5. 异常:cvc-complex-type.2.4.a: Invalid content was found starting with element

    web.xml 出现cvc-complex-type.2.4.a: Invalid content was found starting with element <web-app xmlns= ...

  6. shiro中async-supported报错 cvc-complex-type.2.4.a: Invalid content was found starting with element 'async-supported'. One of '{"http://java.sun.com/xml/ns/ javaee":init-param}' is expected.

    最近都在研究shiro这个框架,今天实施了一下,就报了如下错误: cvc-complex-type.2.4.a: Invalid content was found starting with ele ...

  7. Type cvc-complex-type.2.4.a: Invalid content was found starting with element 'build'.错误的解决方法

    项目突然间爆出了这样的问题: Description Resource Path Location Typecvc-complex-type.2.4.a: Invalid content was fo ...

  8. cvc-complex-type.2.4.a: Invalid content was found starting with element 'display-name'

    cvc-complex-type.2.4.a: Invalid content was found starting with element 'display-name'. One of '{&qu ...

  9. cvc-complex-type.2.4.a: Invalid content was found starting with element ‘init-param’(转)

    在写xml的时候又一次总是报cvc-complex-type.2.4.a: Invalid content was found starting with element 错误,还出现小红叉,在网上找 ...

随机推荐

  1. iterm2 配色

    http://blog.csdn.net/sanwuhai/article/details/48729561

  2. Codeforces 490F Treeland Tour 树上的最长上升子序列

    题目链接:点击打开链接 题意: 给定n个点的树. 以下n个数表示点权. 以下n-1行给出树. 找一条链,然后找出这条链中的点权组成的最长上升子序列. 求:最长上升子序列的长度. 思路: 首先是维护一条 ...

  3. Swift中的switch 和 do while

    switch后面的()能够省略 OC中的switch假设没有break就会穿透(依次运行),在Swift中不会穿透(可理解默认就有break) OC中入股要在case中定义变量,必要要加上{}确定作用 ...

  4. python--面向对象组合

    面向对象的命名空间 类中的方法   类中的静态属性   对象的属性类的组合应用 面向对象的命名空间 class A: country='中国' a=A() a.name='alex' print(a. ...

  5. WWDC2014苹果的“软件”发布会

    WWDC 2014 苹果的"软件"发布会 在今年的 6 月 2 日到 6 日,苹果照例举行了一年一次的全球开发者大会(World Wide Developer Conference ...

  6. Mac OS command line TestNG - “Cannot find class in classpath” error

    直接eclipse执行.xml文件可以正确执行 在mac下执行却总报错: [TestNG] [Error] Cannot find class in classpath 最后解决办法,classpat ...

  7. iOS开发工具篇-AppStore统计工具

    本文转载至 http://mobile.51cto.com/hot-418183.htm 随着iOS开发的流行,针对iOS开发涉及的方方面面,早有一些公司提供了专门的解决方案或工具.这些解决方案或工具 ...

  8. Xcode 6 的新增特性

    本文转载至 http://www.cocoachina.com/ios/20140823/9441.html (via:苹果开发者中心)   Xcode 6 引入了设计和构建软件的崭新方式.Swift ...

  9. 基于EasyDarwin云视频平台的幼儿园视频直播(手机直播/微信直播)解决方案

    一.方案介绍 1.1.方案背景 在2016年10月25日至28日的安博会上,我们看到了不少的幼教平台厂商,我们注意到大部分的幼教平台,为了追求极佳的用户体验,在微信或者APP端能够做到极快的打开速度, ...

  10. 九度OJ 1140:八皇后 (八皇后问题)

    时间限制:1 秒 内存限制:32 兆 特殊判题:否 提交:795 解决:494 题目描述: 会下国际象棋的人都很清楚:皇后可以在横.竖.斜线上不限步数地吃掉其他棋子.如何将8个皇后放在棋盘上(有8 * ...