无法读取架构文档“http://www.springframework.org/schema/beans/spring-beans-3.0.xsd”并且现有解决方案无法正常工作

时间:2013-08-29 00:39:00

标签: xml spring spring-mvc xsd

我有Spring 3.0.5版本,解决方案12对我不起作用。即使我在XML中有错误,我的简单应用程序也能成功运行。我跟着他们使用spring 3.0.1的网站这是不是意味着什么?而我得到的错误是

cvc-elt.1: Cannot find the declaration of element 'beans' 

Referenced file contains errors (http://www.springframework.org/schema/context/spring-context-3.0.xsd).  For more information, right click on the message in the Problems View and select "Show Details..."

我的配置名为simple-servlet.xml

<?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:p="http://www.springframework.org/schema/p"
    xmlns:context="http://www.springframework.org/schema/context"
    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">


    <context:component-scan base-package="com.kiran.mvcdemo" />

    <bean id="viewResolver" class="org.springframework.web.servlet.view.UrlBasedViewResolver">
        <property name="viewClass" value="org.springframework.web.servlet.view.JstlView" />
        <property name="prefix" value="/WEB-INF/" />
        <property name="suffix" value=".jsp" />
    </bean>
</beans> 

0 个答案:

没有答案