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

Getting text out of mixed content

Subject: Getting text out of mixed content
From: sara.mitchell@xxxxxxxxx
Date: Mon, 17 Jan 2000 16:19:56 -0500
xsl fo mixed content para
My apologies up front -- I know this issue has been discussed
but my searches in the XSL archives haven't succeeded and, as
someone else recently posted, I swallowed a dumb pill today. 

I'm struggling to extract only the text out of a paragraph
which allows mixed content. There may be several levels of 
descendant elements. With a first para such as: 

<para>This is the beginning of <field>Field A</field> which you
can use to start the process. </para>

All I get in the output is: 

This is the beginning of Field A

The template I'm using so far does find the first text children 
and the text inside the first element node, but it stops there. 
I'm obviously missing something fundamental and am hoping that 
someone can point out my errors. 

The template I'm using now is:

<xsl:template match="para[1]">
<xsl:for-each select="descendant-or-self::*>
 <xsl:value-of select="text()"/>

I'm using LotusXSL (0.18.2) as my XSL processor.


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

Current Thread


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.
First Name
Last Name
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.