Return-Path: Mailing-List: contact cocoon-dev-help@xml.apache.org; run by ezmlm Delivered-To: mailing list cocoon-dev@xml.apache.org Received: (qmail 82447 invoked from network); 8 Feb 2000 07:05:27 -0000 Received: from lotus2.lotus.com (192.233.136.8) by locus.apache.org with SMTP; 8 Feb 2000 07:05:27 -0000 Received: from internet1.lotus.com (internet1.lotus.com [9.95.4.235]) by lotus2.lotus.com (8.9.3/8.9.3) with ESMTP id CAA03950; Tue, 8 Feb 2000 02:20:35 -0500 (EST) Received: from a3mail.lotus.com (A3MAIL.lotus.com [9.95.5.66]) by internet1.lotus.com (8.9.3/8.9.3) with ESMTP id AAA28902; Tue, 8 Feb 2000 00:36:01 -0500 (EST) Subject: Re: disable-output-escaping To: cocoon-dev@xml.apache.org Cc: Assaf Arkin X-Mailer: Lotus Notes Release 5.0 March 30, 1999 From: "Scott Boag/CAM/Lotus" Date: Tue, 8 Feb 2000 00:35:01 -0500 Message-ID: X-MIMETrack: Serialize by Router on A3MAIL/CAM/H/Lotus() at 02/08/2000 12:37:01 AM MIME-Version: 1.0 Content-type: text/plain; charset=us-ascii Actually, I think I made a bit of a mistake... for DOMs, I don't think I am doing anything with disable-output-escaping anymore, for the very reason that you would see a PI in non-Xalan serializers (and also the standard changed in the last draft so that it doesn't need to be supported for internal DOM nodes used for variables and the like). I just looked at the Cocoon code, it does look like they are using Xerces serializers in any case. What I do for disable-output-escaping is, if the DocumentHandler interface that Xalan writes to supports: public interface RawCharacterHandler { public void charactersRaw (char ch[], int start, int length) throws org.xml.sax.SAXException; } It will write to that method, otherwise it just writes the characters. In the Xalan FormatterToDOM it implements: public void charactersRaw (char ch[], int start, int length) throws SAXException { String s = new String(ch, start, length); append(m_doc.createProcessingInstruction("xslt-next-is-raw", "formatter-to-dom")); append(m_doc.createTextNode(s)); } But I no longer have the class tagged with the RawCharacterHandler interface, for the reasons I named above, so this doesn't get called. Perhaps we could make this optional somehow. Assaf, is this PI something you might be convinced to support? I notice you do support unescaping in the serializers, so maybe we just need to come up with a convention for DOM nodes? BTW, while I'm looking at the Cocoon code, the way Cocoon is currently set up, I don't see how any of the xsl:output options are supported. But I could be misreading the code? Any ideas on how to better support this would certainly be welcome. But, Mike, the bottom line is I don't see how you can do this right now without changing code in Cocoon. Assaf or Stefano might have some ideas. Someone must have run into this before now. -scott Mike Engelhart cc: (bcc: Scott Boag/CAM/Lotus) Subject: Re: disable-output-escaping 02/07/00 11:48 PM Please respond to cocoon-dev Scott Boag/CAM/Lotus wrote: > > Yes, it is supported in Xalan, and through some nasty tricks, it should be > supported in the DOM configuration of Cocoon. It does this by sneaking in > a PI in the DOM tree. If they are using a non-xalan serializer for the DOM > (i.e. the Xerces serializer), this may not work. Since I have the default Xerces configuration of Cocoon, is there any way around this? > Do you mean, instead of getting " Yep... Mike