This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Creating a cdata section using xsl



me> <html>

> Why don't you use the <xsl:element> tag?
> 
> <xsl:template match="person">
>   <xsl:element name="html">
>     <xsl:apply-templates/>
>   </xsl:element>
> </xsl:template>

Because that wouldn't do what was asked for.
That is totally equivalent to

Why don't you use the <xsl:element> tag?

<xsl:template match="person">
  <html>
    <xsl:apply-templates/>
  </html>
</xsl:template>


which creates an html element node in the output.
But the original poster didn't want an html element
he wanted the characters < h t m l > as text.
Hence the subject line of this thread.

David

_____________________________________________________________________
This message has been checked for all known viruses by Star Internet delivered
through the MessageLabs Virus Control Centre. For further information visit
http://www.star.net.uk/stats.asp

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]