Re: [xsl] using xsl and javascript to create dhtml

Subject: Re: [xsl] using xsl and javascript to create dhtml
From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx>
Date: Fri, 19 Mar 2004 18:28:58 -0500

Breaking your items out into a set of "pages" of a given size is a grouping problem, and a pretty simple one. How you then embellish this in HTML with links, or with scripts that do things like collapse or arrange the distinct divs, is then a different issue. While it's not inconceivable to me that Javascript could do this as well, why cripple browsers that can't handle the Javascript? (In part it depends on your approach web design.)

First, design how you want the output to look (and work, where the scripting is concerned). Then, to the extent that your transform needs to break your items into groups (however large), address that separately.

As for the method of grouping in XSLT, look up the position() function used with the mod (modulus) operator.

As for examples, they abound, perhaps someone else can provide one.


At 05:03 PM 3/19/2004, you wrote:

I am transforming xml into an html page that has a list of about 100 items.
I want to put in some kind of pagination where the first 20 are displayed
with links on the bottom to go to the next 20 etc.  Is there a relatively
easy way to accomplish this with xsl?  I have considered using some sort of
javascript and div tags to rewrite the div section as needed.  Any thoughts
or examples on this?


"Thus I make my own use of the telegraph, without consulting
the directors, like the sparrows, which I perceive use it
extensively for a perch." -- Thoreau

XSL-List info and archive:

Current Thread