2012-01-31 1 views
1

나는이 오류를 지나치지 않습니다. mvc xsd가 정확하고 resources 요소가 존재하는지 확인합니다. 왜이 스프링 설정 파일은 MVC가 해결되지 않습니다 자원 요소를왜이 봄 설정 파일은 mvc : resources 요소를 해결하지 못합니다

에서는 SAXParseException : CVC-복잡한 type.2.4.c : 일치하는 와일드 카드는 엄격한, 그러나 선언은 요소에 대한 찾을 수 없습니다 'MVC : 자원'

나는

<beans 
xmlns="http://www.springframework.org/schema/beans" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xmlns:p="http://www.springframework.org/schema/p" 
xmlns:context="http://www.springframework.org/schema/context" 
xmlns:mvc="http://www.springframework.org/schema/mvc" 
xmlns:task="http://www.springframework.org/schema/task" 
xsi:schemaLocation=" 
http://www.springframework.org/schema/beans 
http://www.springframework.org/schema/beans/spring-beans-3.0.xsd 
http://www.springframework.org/schema/context 
http://www.springframework.org/schema/context/spring-context-3.0.xsd 
http://www.springframework.org/schema/task 
http://www.springframework.org/schema/task/spring-task-3.0.xsd 
http://www.springframework.org/schema/mvc 
http://www.springframework.org/schema/mvc/spring-mvc-3.0.xsd"> 

    <context:component-scan annotation-config="true" base-package="com.auto"/> 

    <mvc:annotation-driven /> 
    <mvc:view-controller path="/" view-name="index"/> 

    <mvc:resources location="/resources/" mapping="/resources/**"/> 

    <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver"> 
     <property name="prefix" value="/WEB-INF/views/"/> 
     <property name="suffix" value=".jsp"/> 
    </bean> 

답변

0

이 containig 항아리가 spring-mvc-3.0.xsd이 배치되어 있는지 확인 스프링 프레임 워크의 v3.0.2을 사용하고 있습니다. (내가 기억할 때 그것은 spring-mvc.jar 임)