配置搭建完后进行Post请求测试时报错:

Caused by: org.xml.sax.SAXParseException; lineNumber: 14; columnNumber: 29; cvc-complex-type.2.4.c: 通配符的匹配很全面, 但无法找到元素 'mvc:annotation-driven' 的声明。


查看springmvc配置文件 spring-web.xml如下,发现声明mvc了但没有配置

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xmlns:context="http://www.springframework.org/schema/context"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context.xsd">

加上配置后

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xmlns:context="http://www.springframework.org/schema/context"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
http://www.springframework.org/schema/mvc
http://www.springframework.org/schema/mvc/spring-mvc.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context.xsd">

SSM商城系统开发笔记-问题01-通配符的匹配很全面, 但无法找到元素 'mvc:annotation-driven' 的声明。的更多相关文章

  1. springMVC:通配符的匹配很全面, 但无法找到元素 'mvc:annotation-driven' 的声明

    转自:http://blog.csdn.net/tolcf/article/details/50845483 报错信息:通配符的匹配很全面, 但无法找到元素 'mvc:annotation-drive ...

  2. idea调试SpringMvc, 出现:”通配符的匹配很全面, 但无法找到元素 'mvc:annotation-driven' 的声明“错误的解决方法

    调试json格式输出,出现以下错误: HTTP Status 500 - Servlet.init() for servlet HelloDispatcher threw exception   ty ...

  3. 通配符的匹配很全面, 但无法找到元素 'mvc:annotation-driven' 的声明

    通配符的匹配很全面, 但无法找到元素 'mvc:annotation-driven' 的声明 错误原因是springmvc中的约束信息不对 <beans xmlns="http://w ...

  4. nested exception is org.xml.sax.SAXParseException; lineNumber: 8; columnNumber: 56; cvc-complex-type.2.4.c通配符的匹配很全面, 但无法找到元素 'dubbo:application' 的声明

    严重: Exception sending context initialized event to listener instance of class org.springframework.we ...

  5. 通配符的匹配很全面, 但无法找到元素 'cache:advice' 的声明

    EB-INF\classes\spring-jdbc.xml] is invalid; nested exception is org.xml.sax.SAXParseException; lineN ...

  6. 通配符的匹配很全面, 但无法找到元素 'tx:annotation-driven' 的声明

    启动Tomcat时报错,通配符的匹配很全面, 但无法找到元素 'tx:annotation-driven' 的声明,报错如下 1.从报错可以看到找不到元素   tx:annotation-driven ...

  7. dubbo 常见错误 通配符的匹配很全面, 但无法找到元素 'dubbo:application' java.lang.reflect.MalformedParameterizedTypeException 通配符的匹配很全面, 但无法找到元素 'dubbo:application' 的声明。 Unsupported major.minor version 52.0 (unable to l

    dubbo 常见错误 1. Caused by: java.lang.reflect.MalformedParameterizedTypeException 启动时报错,原因是dubbo 依赖 spr ...

  8. Spring:通配符的匹配很全面, 但无法找到元素 XXXXX' 的声明

    问题:配置Spring的时候容易发生如题的这样一个经常性的错误,错误如下(以context为例) org.springframework.beans.factory.xml.XmlBeanDefini ...

  9. 关于spring”通配符的匹配很全面, 但无法找到元素 'context:component-scan' 的声明“的错误

    关于spring配置的问题 近日学习spring时遇到了这个问题: org.springframework.beans.factory.xml.XmlBeanDefinitionStoreExcept ...

随机推荐

  1. Centos logrotate截断tomcat日志文件

    1. 设置logrotate轮转日志文件 tomcat日志目录:/usr/local/tomcat/apache-tomcat-8.5.34/logs /etc/logrotate.d/目录下创建to ...

  2. 接口返回buffer的16进制数据如何转换

    我们请求接口数据经常会看到buffer数据,这是我们可以使用data.toString()就可以啦~

  3. pages

    pages pages 接受一个数组,每一项都是一个字符串,指定 SWAN App 都有哪些页面.每一项代表页面的[路径 + 文件名],数组第一项代表 SWAN 初始页面. SWAN 中新增或减少页面 ...

  4. mybatis中延迟加载Lazy策略

    延迟加载: lazy策略原理:只有在使用查询sql返回的数据是才真正发出sql语句到数据库,否则不发出(主要用在多表的联合查询) 1.一对一延迟加载: 假设数据库中有person表和card表:其中p ...

  5. Linq in not in\like not like

    别人的博客 http://blog.163.com/lesheng@126/blog/static/357364652010102111051668/ using System.Data.Linq.S ...

  6. js基础补漏

    1.for...in 和 for...of有何区别 for ... in循环由于历史遗留问题,它遍历的实际上是对象的属性名称.一个Array数组实际上也是一个对象,它的每个元素的索引被视为一个属性. ...

  7. [CSP-S模拟测试]:d(贪心+树状数组)

    题目传送门(内部题65) 输入格式 第一行,一个自然数$T$,代表数据组数.对于每组数据:第一行,一个正整数$n$,一个自然数$m$.接下来$n$行,每行两个正整数,$a_i,b_i$. 输出格式 对 ...

  8. Matlab中imfilter()函数的用法

    Matlab中imfilter()函数的用法 功能:对任意类型数组或多维图像进行滤波.用法:B = imfilter(A,H) B = imfilter(A,H,option1,option2,... ...

  9. ORA-00972

    SQL> select to_char(sysdate,'YYYY-MM-DD HH24:MI:SS') as 日期时间 from dual;select to_char(sysdate,'YY ...

  10. Gym 100942A Three seamarks

    题目链接: http://codeforces.com/problemset/gymProblem/100942/A ----------------------------------------- ...