web.xml配置文件中true报错的解决方案

时间:2020-02-08 13:44:38   收藏:0   阅读:56

true报错的解决方案:

解决方法一:

1. 在eclipse中配置xml

1、?http://www.springmodules.org/schema/cache/springmodules-cache.xsd
2、?http://www.springmodules.org/schema/cache/springmodules-ehcache.xsd

2. 然后再将这两个xsd加入到web.xml中就搞定了 ,如下面代码:

技术分享图片

解决方法二:

1. true是web.xml 3.0的新特性,只需将

<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
    xmlns="http://Java.sun.com/xml/ns/javaee" 
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" 
    id="WebApp_ID" version="2.5">

2. 改成:

<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
    xmlns="http://java.sun.com/xml/ns/javaee" 
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" 
    id="WebApp_ID" version="3.0">

即可解决。

原文:https://www.cnblogs.com/xianyao/p/12276002.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!