Vlad This is more about how to write out escaped tags rather than actually converting them to valid XML.
Derek >>> [EMAIL PROTECTED] 2005/03/01 08:10:26 AM >>> I have found something similar: http://www.dpawson.co.uk/xsl/sect2/N2215.html Does anybody tried it to solve our problem? "Derek Hohls" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Vlad > > I have never done this; I am still struggling with the htmlArea > component that is used with Cocoon forms... it saves all the > data as escaped tags (as per your example) and that makes > it impossible to post-process... what Cocoon needs is a transformer > that takes a file with escaped tags and converts them to valid XML. > > Any takers to code this?? > > Derek > > >>> [EMAIL PROTECTED] 2005/02/28 01:25:47 PM >>> > Derek, > > that was very helpful. It would work if there wouldn't be one moment. > I > noticed that actually all the data in DB is in such format: > > <contact> > <name>Chris</name> > <surname>Lautre</surname> > <address>Plomipuu 16</address> > <email>[EMAIL PROTECTED]</email> > <phone></phone> > </contact> > > Is it possible to convert it to the normal tags and then apply your > method? > > Vlad > > "Derek Hohls" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > > You may need to add in a namespace to the file below to > > make it a valid XML file e.g. > > > > <pcomponentobjectOut > > xsi:type="ns2:DBConnection1_ComponentObjectUser" > > xmlns:xsi="http://apache.org/cocoon/xsi/1.0"> > > ... > > > > Then the following works (under my Cocoon 2.1.5): > > > > <?xml version="1.0"?> > > <xsl:stylesheet version="1.0" > > xmlns:xsl="http://www.w3.org/1999/XSL/Transform" > > xmlns:xsi="http://apache.org/cocoon/xsi/1.0" > > > > > > > <xsl:template match="pcomponentobjectOut"> > > <xsl:apply-templates/> > > </xsl:template> > > > > <xsl:template match="componentClob"> > > <xsl:apply-templates/> > > </xsl:template> > > > > <xsl:template match="contact"> > > <xsl:value-of select="surname"/>,<xsl:value-of select="name"/> > > </xsl:template> > > > > <xsl:template match="*"> > > </xsl:template> > > > > </xsl:stylesheet> > > > > > > HTH. > > > > > > >>> [EMAIL PROTECTED] 2005/02/28 11:41:10 AM >>> > > Hi All, > > > > I have a web service, which returns me code like that: > > > > > -------------------------------------------------------------------------- > -- > > -- > > <pcomponentobjectOut > xsi:type="ns2:DBConnection1_ComponentObjectUser"> > > <componentClob xsi:type="xsd:string"><contact> <name>Chris</name> > > <surname>Lautre</surname> <address>Plomipuu 16</address> > > <email>[EMAIL PROTECTED]</email> <phone></phone> </contact> > <contact> > > <name>Vlad</name> <surname>Golodov</surname> <address>Paasiku 22 - > > 155</address> <email>[EMAIL PROTECTED]</email> <phone>+37256639190</phone> > > </contact></componentClob> > > <componentId xsi:type="xsd:decimal">97</componentId> > > <componentName xsi:type="xsd:string">Address Book For > > Other</componentName> > > <componentType xsi:type="xsd:string">ADDRESSBOOK</componentType> > > <dateCreated > > xsi:type="xsd:dateTime">2005-02-21T11:46:50.000Z</dateCreated> > > <dateUpdated xsi:type="xsd:dateTime" xsi:nil="true" /> > > <description xsi:type="xsd:string">New Address Book For > > Other</description> > > <groupId xsi:type="xsd:decimal">11</groupId> > > <newPosts xsi:type="xsd:string" xsi:nil="true" /> > > <ownerUserName xsi:type="xsd:string">clautre</ownerUserName> > > </pcomponentobjectOut> > > > -------------------------------------------------------------------------- > -- > > -- > > > > In xslt I need to parse componentClob and iterate through the > contact > > tags. > > > > That code gives me the content of the componentClob: > > > > > -------------------------------------------------------------------------- > -- > > - > > <xsl:template match="*/return/pcomponentobjectOut"> > > <xsl:value-of select="componentClob" > disable-output-escaping="yes"/> > > </xsl:template> > > > -------------------------------------------------------------------------- > -- > > - > > > > I was trying to iterate through the content of clob, but all was > > vainly. > > > > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
