SSM整合时,配置文件报错

在进行SSM框架整合时,配置文件开头是这样写的:

        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-4.0.xsd
http://www.springframework.org/schema/context 

http://www.springframework.org/schema/context/spring-context-4.0.xsd"

然后有个小红叉报如下错误:

Failed to read schema document 'http://www.springframework.org/schema/context/spring-context-4.0.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root   element of the document is not <xsd:schema>. - cvc-complex-t

经查证发现,把配置文件中的4.0改成3.0就没错了,而我的jar包都是4.0.x的,Myeclipse是2017版的!Myeclipse真是个奇怪的东西!不明白!!!!!!!

猜你喜欢

转载自blog.csdn.net/lxc_1206/article/details/80022837