[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: text output literal text

Subject: RE: text output literal text
From: Kay Michael <Michael.Kay@xxxxxxx>
Date: Fri, 2 Jun 2000 09:19:35 +0100
output literal text in xsl
> * Contained in my xsl file I have a slab of text
>     marked-up using tags
> *  This is so that I can perform some other xsl
>      conditions on these paragraphs to determine
>      which of these paragraphs will be included in
>      the resulting  .xml file
> *  I simply want this text to appear in the result
>      tree. I am using <xsl:text> to achieve this
>      however have experienced some errors.

You are confused! This is not what <xsl:text> is for.
> 
> <xsl:template match='/'>
>     <xsl:text><para></xsl:text>
>          <xsl:text>A block of text</xsl:text>
>     <xsl:text></para></xsl:text>
> </xsl:template>
> 
A stylesheet must be a well-formed XML document, the <para> tags here are
not properly nested.

> <xsl:template match='/'>
>     <xsl:text/><para>
>          <xsl:text>A block of text</xsl:text>
>     <para><xsl:text/>
> </xsl:template>
> 
This is OK, and equivalent to
<xsl:template match="/">
<para>A block of text</para>
</xsl:template>

 
> <xsl:template match='/'>
>     <xsl:text><para>
>         <xsl:text>A block of text</xsl:text>
>     <para></xsl:text>
> </xsl:template>
>
Like it says: 
> xsl:text must not have any child elements
> 
> Any suggestions or advice would be warmly welcomed.
> 

Need to understand what you are trying to achieve!

Mike Kay


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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.