ColdFusion:标签错误
尝试使用
标签填充 PDF 表单字段时出现此错误
文档中根元素后面的标记必须格式正确。
当我给出 overwritedata="yes"
时,相同的代码可以正常工作,但会覆盖现有数据。 我注意到在执行此操作时我看到的文档中的“数组”上有一些字段:
。 新的、被覆盖的文档中缺少“数组”部分。
异常是这样的:
rg.jdom.input.JDOMParseException: Error on line 92: The markup in the document following the root element must be well-formed. at org.jdom.input.SAXBuilder.build(SAXBuilder.java:468) at org.jdom.input.SAXBuilder.build(SAXBuilder.java:851) at coldfusion.pdf.XFADataXMLGenerator.createFormXMLData(XFADataXMLGenerator.java:108) at coldfusion.tagext.lang.PDFFormTag.doEndTag(PDFFormTag.java:276) at cfpopulatePDF2ecfm344978773.runPage(C:\ColdFusion8\wwwroot\CFIDE\populatePDF.cfm:26) ...
<cfpdfform action="populate" source="#sourceDirectory#\T.pdf" destination="#destinationDirectory#\test3343.pdf" > <cfpdfsubform name="form1"> <cfpdfsubform name="pageOne"> <cfpdfsubform name="overallSection" > <cfpdfsubform name="overallQA" > <cfpdfformparam name="overallRating" value="2"/> </cfpdfsubform> </cfpdfsubform> </cfpdfsubform> </cfpdfsubform> </cfpdfform>
Am getting this error when try to populate a PDF form field using the <cfpdf>
tag
The markup in the document following the root element must be well-formed.
When I give overwritedata="yes"
the same code works fine, but overwrites the existing data. I noticed there was some fields on the an "arrary" in the document which I saw when I did this: <cfdump var="#resultstruct#">
. The "array" part is missing in the new, overwritten document.
The exception goes like this:
rg.jdom.input.JDOMParseException: Error on line 92: The markup in the document following the root element must be well-formed. at org.jdom.input.SAXBuilder.build(SAXBuilder.java:468) at org.jdom.input.SAXBuilder.build(SAXBuilder.java:851) at coldfusion.pdf.XFADataXMLGenerator.createFormXMLData(XFADataXMLGenerator.java:108) at coldfusion.tagext.lang.PDFFormTag.doEndTag(PDFFormTag.java:276) at cfpopulatePDF2ecfm344978773.runPage(C:\ColdFusion8\wwwroot\CFIDE\populatePDF.cfm:26) ...
<cfpdfform action="populate" source="#sourceDirectory#\T.pdf" destination="#destinationDirectory#\test3343.pdf" > <cfpdfsubform name="form1"> <cfpdfsubform name="pageOne"> <cfpdfsubform name="overallSection" > <cfpdfsubform name="overallQA" > <cfpdfformparam name="overallRating" value="2"/> </cfpdfsubform> </cfpdfsubform> </cfpdfsubform> </cfpdfsubform> </cfpdfform>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
明显的问题:文档中根元素后面的标记是否格式良好?
您看到的是 XML 解析器错误消息,而不是
特定消息。确保您处理的文档的格式符合 XML 规则。
The obvious question: Is the markup in the document following the root element well-formed?
You are seeing an XML parser error message, not a
<cfpdf>
specific message.Make sure that the document you process is well-formed according to XML rules.