xsl-list
[Top] [All Lists]

RE: Select issue with some attr and others not.

2004-04-16 09:31:55
Well what I would like to do is set a param and be able to use the param to
deside what lang is brought back. 
SO depending on what the param states, it would bring back en-EN or es-ES
john

-----Original Message-----
From: David Carlisle [mailto:davidc(_at_)nag(_dot_)co(_dot_)uk] 
Sent: Friday, April 16, 2004 12:29 PM
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: Re: [xsl] Select issue with some attr and others not.


AND I want to pull back this result with xsl (depeding on the
language.)

You didn't say what that transform was, is it just dropping the spanish?

If so you just need a stylesheet with two templates, one that copies
everything

<xsl:template match="node()">
<xsl:copy>
<xsl:copy-of select="@*/>
<xsl:apply-templates/>
</xsl:copy>
</xsl:template>

and then one to not copy spanish

<xsl:template  match="*[(_at_)lang='es-ES']"/>

You probably won't get the output written using CDATA but that's just a
syntactic quirk and doesn't affect the way the files are processed by an
XML application.

David

________________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

--+------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--+--