|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Extracting text
Jon,
Ordinarily, one would do this implicitly by way of the default traversal, as in simply <xsl:template match="p"> <xsl:apply-templates/> </xsl:template> <xsl:template match="span | br"/> <!-- this template suppresses the span and br --> If you do this you'll find your text is "extracted". In particular cases, one might be more explicit about the extraction: <xsl:template match="p">
<xsl:apply-templates select="text()"/>
<!-- this instruction selects only text node children
and processes them -->
</xsl:template>... but not uncommonly when we see this sort of thing, it's an indication of either bad coding in the XSLT, bad design of the source XML, or both. Yet you can certainly do it, and might even have a good reason to. I hope this helps, Wendell At 06:31 PM 5/25/2005, you wrote: 'lo all, ====================================================================== Wendell Piez mailto:wapiez@xxxxxxxxxxxxxxxx Mulberry Technologies, Inc. http://www.mulberrytech.com 17 West Jefferson Street Direct Phone: 301/315-9635 Suite 207 Phone: 301/315-9631 Rockville, MD 20850 Fax: 301/315-8285 ---------------------------------------------------------------------- Mulberry Technologies: A Consultancy Specializing in SGML and XML ======================================================================
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








