我在中创建了一个文件faces-config.xml给出了一个错误
Referenced file contains errors (jar:file:/D:/eclips/eclipse k/plugins/org.jboss.tools.jst.web_3.5.0.Final-v20130717-0309-B75.jar!/catalog/web-facesconfig_2_2.xsd). faces-config.xml
<?xml version="1.0" encoding="UTF-8"?>
<faces-config
xmlns="http://xmlns.jcp.org/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee
http://xmlns.jcp.org/xml/ns/javaee/web-facesconfig_2_2.xsd"
version="2.2">
</faces-config>删除下面一行时,错误指示在faces-config.xml中消失
http://xmlns.jcp.org/xml/ns/javaee/web-facesconfig_2_2.xsd更新我如何解决这个问题?
发布于 2013-09-28 15:21:10
您指定了两次http://xmlns.jcp.org/xml/ns/javaee,所以删除一个。
发布于 2017-05-08 18:22:37
禁用XSD文件缓存为我解决了问题--对于Eclipse,相关的选项是Window>Preferences->General->>Cache->禁用缓存。选中那个复选框,然后清理和建造。我认为,在我的例子中,我试图在没有互联网连接的wifi上进行重建,Eclipse试图验证这些文件,但无法,并决定显示这种错误。
发布于 2014-02-18 13:32:58
对我来说,删除重复的命名空间会在编辑faces-config.xml时禁用内容辅助功能,这会带来令人不快的副作用。
这些具有“重复”名称空间的标头在任何地方都是指定的,特别是faces-config,在JSF规范中有提到。即使是W3C XML规范也具有类似的例子的特性。
因此,问题的标题似乎是正确的。安装Eclipse工具的最新更新为我解决了这个问题。
它可能与这些JBoss工具问题有关:JBIDE-14439、JBIDE-15605。
https://stackoverflow.com/questions/18842486
复制相似问题