<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5"
xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_5.xsd">
Run Code Online (Sandbox Code Playgroud)
引用文件包含错误(http://java.sun.com/xml/ns/j2ee/web-app_2_5.xsd).有关更多信息,请右键单击"问题视图"中的消息,然后选择"显示详细信息..."
通过文件"web.xml"验证文件"web-app_2_5.xsd"时检测到以下错误.在大多数情况下,可以通过直接验证"web-app_2_5.xsd"来检测这些错误.但是,只有在web.xml的上下文中验证web-app_2_5.xsd时才会出现错误.
在细节上,我看到了一堆这些:
s4s-elt-character:除xs:appinfo和xs:documentation之外的架构元素中不允许使用非空白字符.看到'var _U ="undefined";'
Saz*_*man 52
如果更换j2ee的javaee,它会正常工作.
编辑:
<web-app version="2.5"
xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
Run Code Online (Sandbox Code Playgroud)
编辑:
要了解与此错误相关的任何内容.请关注链接.在这里,您将找到Java EE部署描述符(web.xml)的模式.
小智 33
更换
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_5.xsd">
Run Code Online (Sandbox Code Playgroud)
同
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee;http://java.sun.com/xml/ns/j2ee/web-app_2_5.xsd">
Run Code Online (Sandbox Code Playgroud)
解决方案是您必须在URL之间放置分号
我相信你不会再次得到错误:)
小智 12
我建议你;在 2 段之间添加:
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee和http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
像这样:
:xsi:schemaLocation="http://java.sun.com/xml/ns/javaee;http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
Run Code Online (Sandbox Code Playgroud)
在xsi:schemaLocation之间添加分号,如下所示
"http://java.sun.com/xml/ns/javaee;http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
<servlet-name>这也解决了我在标语行中的错误。
“cvc-id.3:身份约束‘web-common-servlet-name-uniqueness’的字段与元素‘web-app’匹配,但该元素没有简单类型。”
| 归档时间: |
|
| 查看次数: |
36924 次 |
| 最近记录: |