Subject: Re: [xsl] Efficient Recursive Algorithms in XSLT (Was: Re: Constructing X number of elements) From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx> Date: Tue, 21 Aug 2001 13:32:44 -0400 |
<my:stars> <!-- you'll need to have declared the 'my' namespace --> <img src="star.gif" alt="first star"/> <img src="star.gif" alt="second star"/> <img src="star.gif" alt="third star"/> <img src="star.gif" alt="fourth star"/> <img src="star.gif" alt="fifth star"/> </my:stars>
Then, <xsl:template match="movie"> ... <xsl:copy-of select="$stars[position() <= @rating]" /> ... </xsl:template>
Cheers, Wendell
This solution will crash some XSLT processors and is generally less efficient (both
in time and space) than another general approach for implementing recursive
algorithms....
====================================================================== 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 ======================================================================
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] Efficient Recursive Algorithm, Dimitre Novatchev | Thread | [xsl] separating elements/attribute, Samina Islam |
Re: [xsl] upper case, Wendell Piez | Date | [xsl] Passing the current node list, Paul Ackley |
Month |