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

AW: AW: exlt set.distinct.template.xsl ?

Subject: AW: AW: exlt set.distinct.template.xsl ?
From: "Braumüller, Hans" <h.braumueller@xxxxxxxxxxxx>
Date: Fri, 15 Mar 2002 12:20:12 +0100
xsl set distinct
Thanks Jenni,

for explaining how to handle correctly your templates.

I have begin last july designing with xsl for the frontend of a business
application on my job. Maybe you should consider, to put this part of your
explanation in your how to do page, because i think, i am not the only one,
which have had trouble, to fit all together in a working example. Probably
is enough to illustrate after your sentence, that it shall be used in mode
modus, with  <xsl:template match="node" mode="set:modul"> .The problem often
is that the lenguage involved at this kind of sites, never mind, what is it,
Js, xsl, xhtml, perl, cgi, etc, it´s so specific, that you must learn first
the vocubary, before understanding it.

Thanks for your patience,

Hans Braumüller
Mail Art not War
http://crosses.net


> -----Ursprüngliche Nachricht-----
> Von: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> [mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]Im Auftrag von Jeni
> Tennison
> Gesendet: Freitag, 15. März 2002 11:32
> An: Braumüller, Hans
> Cc: 'xsl-list@xxxxxxxxxxxxxxxxxxxxxx'
> Betreff: Re: AW:  exlt set.distinct.template.xsl ?
> 
> 
> Hi Hans,
> 
> > to the transformation stylesheet set.distinct.1.xsl, because i want
> > to customize the output adding an semi-colon (;) and the second
> > adaption was changing copy-of with value-of, to some obtain some
> > output.
> >
> > How can i gain the same result without changing the original
> > template from exslt ?
> 
> Just to explain the design of the set:distinct (and some of the other
> set:*) template...
> 
> You cannot return a node set from an XSLT template. Therefore it's
> impossible for set:distinct to return the 'distinct' nodes. Instead,
> it applies templates to the distinct nodes in 'set:distinct' mode.
> 
> What happens to them then is up to you. By default, as you've seen,
> they get copied. If you want to get their values, then go ahead and
> override the template in set:distinct mode - that's precisely why the
> set:distinct template applies templates to the distinct nodes rather
> than immediately copying them.
> 
> If you simply have a template matching @country attributes in
> set:distinct mode within your stylesheet, then you should get what you
> want:
> 
> <xsl:template match="@country" mode="set:distinct">
>   <xsl:value-of select="." />;
> </xsl:template>
> 
> You don't need to delete the template from the
> set.distinct.template.xsl stylesheet, though - since you're importing
> it, your template will be used in preference to the one that's in the
> utility stylesheet.
> 
> Cheers,
> 
> Jeni
> 
> ---
> Jeni Tennison
> http://www.jenitennison.com/
> 
> 
>  XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
> 

 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.