Try loading the XML with net.liftweb.util.PCDataXmlParser ? Cheers, Tim
On Aug 9, 6:58 pm, Ross Mellgren <[email protected]> wrote: > Loading this XML using XML.loadString works fine for me, so I suspect > there is something else going on here (e.g. formatting of the string, > encoding you use, code that loads the XML, etc.). Can you post a small > code snippet reproducing the issue? > > -Ross > > On Aug 9, 2009, at 1:54 PM, fbettag wrote: > > > > > > > The Problem seems to be the newlines. when i do .replace("\n", "") > > before XML.loadString() it works.. strange, any explaination? > > > On Aug 9, 6:34 pm, fbettag <[email protected]> wrote: > >> Hi there, > > >> i know this is not the right place, but i wanted your opinions first. > >> I'm trying to run XML.loadString onto this: > > >> <body> > >> <div id="wrapper"> > >> <div id="header"> > >> <lift:Content.headline /> > >> <lift:Content.subheadline /> > >> <lift:Content.menu /> > >> </div> > >> </div> > > >> <div id="content"> > >> <show:Content /> > >> </div> > > >> <div id="footer"> > >> <lift:Content.footer /> > >> </div> > >> </body> > > >> The Problem appears to be with div#header, as soon as i remove it - > >> it > >> works, as soon as i put in (EVEN AN EMPTY) div#header i get this > >> error: > > >> org.xml.sax.SAXParseException: The element type "div" must be > >> terminated by the matching end-tag "</div>". > >> at > >> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse > >> (AbstractSAXParser.java:1269) > >> at javax.xml.parsers.SAXParser.parse(SAXParser.java:375) > >> at scala.xml.parsing.FactoryAdapter.loadXML > >> (FactoryAdapter.scala:292) > >> at scala.xml.parsing.NoBindingFactoryAdapter.loadXML > >> (NoBindingFactoryAdapter.scala:60) > >> at scala.xml.XML$.load(XML.scala:68) > >> at scala.xml.XML$.loadString(XML.scala:84) > >> at ag.bett.lift.cms.comet.Others$.show(Others.scala:97) > > >> Any ideas? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Lift" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/liftweb?hl=en -~----------~----~----~----~------~----~------~--~---
