Subject: Re: [xsl] Preserving XHTML markup From: David Carlisle <davidc@xxxxxxxxx> Date: Mon, 4 Feb 2002 21:42:19 GMT |
quoting XML markup with CDATA is almost always a bad idea as it loses all the structure. Similarly disable-output-encoding is almost always a bad thing to suggest (see any of thousands of postings to this list on that subject) The markup was removed as the original poster used value-of which is specified as producing teh string value, changing that to copy-of will give a copy of the tree structure as required. David -- Adam Sherman [Mon, 04 Feb 2002 12:37:53 -0500]: >(Newbie Alert!) > >xml: ><mycustomtag> > Some html <b>here</b>. ></mycustomtag> > > >How do I preserve things so I end up with: > ><p> > Some html <b>here</b>. ></p> > >My XSLT stylesheet loses all the markup in the children of >selected/processed nodes... your problem is your XML itself. it should be: <mycustomtag> <![CDATA[Some html <b>here</b>.]]> </mycustomtag> then your XSL should be: <p> <xsl:value-of select="mycustomtag" disable-output-escaping="true"/> </p> --- Eric Vitiello Perceive Designs <www.perceive.net> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list _____________________________________________________________________ This message has been checked for all known viruses by Star Internet delivered through the MessageLabs Virus Scanning Service. For further information visit http://www.star.net.uk/stats.asp or alternatively call Star Internet for details on the Virus Scanning Service. XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Preserving XHTML markup, Julian Reschke | Thread | Re: [xsl] Preserving XHTML markup, Thomas B. Passin |
RE: [xsl] xsl:include, Jason Macki | Date | Re: [xsl] Preserving XHTML markup, David Carlisle |
Month |