A Xalan solution could be to use an extension element. Take a look at the redirect extension source; I believe if you plug a StringWriter into the ContentHandler inplace of the FileOutputStream, and then do a toString() you will get what you want. Rob. -----Original Message----- From: James Melton [mailto:[EMAIL PROTECTED]] Sent: 11 July 2001 15:13 To: [EMAIL PROTECTED] Subject: Re: How to serialize recursively the content of one node into a String with Xalan J2 I don't think this is an XSLT question, since there is no difference XML-wise between the input and the output. I think the question must be about having a (DOM?) representation, and serializing starting from an arbitrary node. Still, it's not a Xalan question. I suppose it must be a parser question. Jim. Gary L Peskin wrote: > > Vincent -- > > Since this is a pure XSLT question, you might want to ask this over on > the Mulberry XSL-List. They have a lot of folks over there and someone > might have done this before. > > Gary > > MAHE Vincent FTRD/DIH/REN wrote: > > > > Is it possible to serialize as a java string the content of one node and all > > its descendants ? > > > > For example, if I have the following node : > > <toto class="titi"> > > <titi>bla bla</titi> > > </toto> > > > > I want to get the following string : "<toto class="titi">\n<titi>bla > > bla</titi>\n</toto>" > > > > Thanks. > > > > Vincent Mahe -- ____________________________________________________________ James Melton CyLogix 609.750.5190 609.750.5100 [EMAIL PROTECTED] www.cylogix.com
