[opencms-dev] CmsXmlException when pasting news from word toHtmlWidget

Jonathan Woods jonathan.woods at scintillance.com
Sat Jun 10 18:44:26 CEST 2006


Zhibin -

Did you paste it directly into the XML element called "Content"?  If so, you
should make sure that it's treated as CDATA, which means your Word content
can have just about any character sequence in it without affecting the
structure of the XML document:

<content><![CDATA[any content you like here, with the CDATA markup including
square brackets]]></content>

Jon

-----Original Message-----
From: opencms-dev-bounces at opencms.org
[mailto:opencms-dev-bounces at opencms.org] On Behalf Of Huang Zhibin
Sent: 10 June 2006 08:54
To: opencms-dev at opencms.org
Subject: [opencms-dev] CmsXmlException when pasting news from word
toHtmlWidget

Hi, list,
  Today I copy one news from word and paste it in the Content (<xsd:element
name="Content" type="OpenCmsHtml" /> ... <layout element="Content" 
widget="HtmlWidget" 
configuration="source,link,anchor,formatselect,imagegallery,downloadgallery,
linkgallery,htmlgallery,tablegallery,height:400px" 
/>), and meet with one problem. I do not know how to solve it, does anyone
can give me some suggestions?
  Thanks for your kindness. (BTW: I included that news as an attachment for
you to test.) Regards, Zhibin

org.opencms.xml.CmsXmlException: Unmarshalling xml document failed.
	at org.opencms.xml.CmsXmlUtils.unmarshalHelper(CmsXmlUtils.java:599)
	at org.opencms.xml.CmsXmlUtils.unmarshalHelper(CmsXmlUtils.java:570)
	at
org.opencms.xml.content.CmsXmlContentFactory.unmarshal(CmsXmlContentFactory.
java:115)

	at
org.opencms.xml.content.CmsXmlContentFactory.unmarshal(CmsXmlContentFactory.
java:172)

	at
org.opencms.xml.content.CmsXmlContentFactory.unmarshal(CmsXmlContentFactory.
java:129)

	at
org.opencms.workplace.editors.CmsXmlContentEditor.writeContent(CmsXmlContent
Editor.java:1448)

	at
org.opencms.workplace.editors.CmsXmlContentEditor.actionSave(CmsXmlContentEd
itor.java:470)

	at
org.opencms.workplace.editors.CmsXmlContentEditor.actionSave(CmsXmlContentEd
itor.java:448)

	at
com.ibm._jsp._editor_5F_form._jspService(_editor_5F_form.java:191)
	at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:88)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java(Compiled
Code))
	at
com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java(C
ompiled
Code))
	at
com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.
java(Compiled
Code))
	at
com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(Gener
icServletWrapper.java:117)

	at 
com.ibm.ws.jsp.webcontainerext.JSPExtensionServletWrapper.handleRequest(JSPE
xtensionServletWrapper.java:171)

	at 
com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.include(WebAppRequest
Dispatcher.java:552)

	at 
org.opencms.flex.CmsFlexRequestDispatcher.includeExternal(CmsFlexRequestDisp
atcher.java:194)

	at 
org.opencms.flex.CmsFlexRequestDispatcher.include(CmsFlexRequestDispatcher.j
ava:170)

	at org.opencms.loader.CmsJspLoader.service(CmsJspLoader.java:433)
	at 
org.opencms.flex.CmsFlexRequestDispatcher.includeInternalWithCache(CmsFlexRe
questDispatcher.java:423)

	at 
org.opencms.flex.CmsFlexRequestDispatcher.include(CmsFlexRequestDispatcher.j
ava:174)

	at
org.opencms.loader.CmsJspLoader.dispatchJsp(CmsJspLoader.java:467)
	at org.opencms.loader.CmsJspLoader.load(CmsJspLoader.java:412)
	at 
org.opencms.loader.CmsResourceManager.loadResource(CmsResourceManager.java:7
19)

	at org.opencms.main.OpenCmsCore.showResource(OpenCmsCore.java:1362)
	at org.opencms.main.OpenCmsServlet.doGet(OpenCmsServlet.java:151)
	at org.opencms.main.OpenCmsServlet.doPost(OpenCmsServlet.java:163)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:763)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java(Compiled
Code))
	at 
com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java(C
ompiled 
Code))
	at 
com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.
java(Compiled 
Code))
	at 
com.ibm.ws.webcontainer.servlet.CacheServletWrapper.handleRequest(CacheServl
etWrapper.java:80)

	at 
com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java(Compile
d 
Code))
	at 
com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java(Compi
led 
Code))
	at 
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(Ht
tpInboundLink.java(Compiled 
Code))
	at 
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(Ht
tpInboundLink.java(Compiled 
Code))
	at 
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(HttpInboundLink.j
ava:276)

	at 
com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.sendToDiscrimin
aters(NewConnectionInitialReadCallback.java:201)

	at 
com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.complete(NewCon
nectionInitialReadCallback.java:103)

	at 
com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManage
r.java(Compiled 
Code))
	at 
com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java
(Compiled 
Code))
	at 
com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun(WorkQueueManager.java
(Compiled 
Code))
	at 
com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.jav
a(Compiled 
Code))
	at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java(Compiled
Code))
Caused by: org.dom4j.DocumentException: Error on line 29 of document  : An 
invalid XML character (Unicode: 0x0) was found in the CDATA section. Nested 
exception: An invalid XML character (Unicode: 0x0) was found in the CDATA 
section.
	at org.dom4j.io.SAXReader.read(SAXReader.java:482)
	at org.opencms.xml.CmsXmlUtils.unmarshalHelper(CmsXmlUtils.java:597)
	... 43 more





More information about the opencms-dev mailing list