Try the following work around: <THING foo="100"> <xsp:attribute name="data">string of " characters</xsp:attribute> </THING>
Vadim > From: Benjamin Grant [mailto:[EMAIL PROTECTED]] > > Hello, > > I am encountering a problem when applying the serverpages generator to files > which contain XML elements that have attributes which contain entity > references. > > The serverpages generator is failing during compilation, because Cocoon is > resolving entity references, INCLUDING those within elements outside of the > xsp namespace, and specifically entity references within attributes of those > elements. > > I understand this may be "normal" since the file is processed by a SAX parser > inside Cocoon, but it seems like there ought to be a way to override the > resolution for entities within elements outside of the XSP namespace when > using the serverpages generator. I've looked around a lot, read all the > docs. Maybe I missed it. > > > Sample: > > <xsp:... blah blah> > > <page> > <STUFF> > <THING foo="100" data="string of " characters"/> > <THING foo="101" data="another string thing"/> > </STUFF> > </page> > > </xsp...> > > This is handled by something standard like: > > <map:match pattern="stuff/**.xml"> > <map:generate type="serverpages" src="stuff/{1}.xml"/> > <map:transform src="style/stuff.xsl"/> > <map:serialize type="html"/> > </map:match> > > And produces, in the work directory, java sourcecode output like this: > > xspAttr.addAttribute("", "foo", "foo", "CDATA", "string of " > characters"); > > Which the compiler chokes on due to the mismatched quote characters. > > Any thoughts on ways around this, aside from resorting to putting everything > in distinct elements, would be most appreciated. --------------------------------------------------------------------- Please check that your question has not already been answered in the FAQ before posting. <http://xml.apache.org/cocoon/faqs.html> To unsubscribe, e-mail: <[EMAIL PROTECTED]> For additional commands, e-mail: <[EMAIL PROTECTED]>