ICEFaces“序言中不允许有内容” 错误

发布于 2024-07-29 22:29:52 字数 1213 浏览 4 评论 0原文

我有一个 JSF/ICEFaces 应用程序,工作正常,但我不断收到此错误。 尽管应用程序正常继续,但我仍然时不时地收到该错误。 据我了解,它抱怨文件中的 XML 标头之前有某些内容,但我不确定为什么会出现这种情况,我正在使用 ICEfaces 来为 AJAX 来回生成 XML。

有任何想法吗?

谢谢,

Tam

12:59:17,010 错误 [消化器] 第 1 行第 1 列解析致命错误:序言中不允许出现内容。 org.xml.sax.SAXParseException:序言中不允许有内容。 在 org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(来源未知) 在 org.apache.xerces.util.ErrorHandlerWrapper.fatalError(来源未知) 在 org.apache.xerces.impl.XMLErrorReporter.reportError(来源未知) 在 org.apache.xerces.impl.XMLErrorReporter.reportError(来源未知) 在 org.apache.xerces.impl.XMLErrorReporter.reportError(来源未知) 在 org.apache.xerces.impl.XMLScanner.reportFatalError(来源未知) 在 org.apache.xerces.impl.XMLDocumentScannerImpl$PrologDispatcher.dispatch(来源未知) 在 org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(来源未知) 在 org.apache.xerces.parsers.XML11Configuration.parse(来源未知) 在 org.apache.xerces.parsers.XML11Configuration.parse(来源未知) 在 org.apache.xerces.parsers.XMLParser.parse(来源未知) 在 org.apache.xerces.parsers.AbstractSAXParser.parse(来源未知) 在 org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(来源未知)

I have an JSF/ICEFaces application that is works fine but I keep getting this error. Although the application continues normally, I still get that error now and then. As far as I understand it's complaining about having something in the file before XML header but I'm not sure why I'm getting this I'm using ICEfaces that generates XML back and forth for AJAX.

Any ideas?

Thanks,

Tam

12:59:17,010 ERROR [Digester] Parse Fatal Error at line 1 column 1: Content is not allowed in prolog.
org.xml.sax.SAXParseException: Content is not allowed in prolog.
at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
at org.apache.xerces.util.ErrorHandlerWrapper.fatalError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLScanner.reportFatalError(Unknown Source)
at org.apache.xerces.impl.XMLDocumentScannerImpl$PrologDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

横笛休吹塞上声 2024-08-05 22:29:54

你能把麻烦的一行粘贴到顶部吗? 它可能只是额外的换行符或标签外的错误字符。

Could you paste the top of the troublesome line. It might just be extra linefeeds or an erroneous character outside a tag.

皓月长歌 2024-08-05 22:29:52

如果 jspx 不是有效的 XML 文件,通常会发生这种情况。 应该有一个根 f:view 元素,并且命名空间导入应放置在其下方。

看看这个file 查看 jspx 文件的示例结构。

This typically occurs if a jspx is not a valid XML file. There should be one root f:view element, and namespace imports should be placed under it.

Check out this file for an example structure of jspx file.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文