RE: [xsl] Reading Attributes in XSL

Subject: RE: [xsl] Reading Attributes in XSL
From: "Haarman, Michael" <mhaarman@xxxxxxxxx>
Date: Tue, 15 Nov 2005 13:34:31 -0600
> -----Original Message-----
> From: pankaj.ahuja@xxxxxxxxxxxx

> I cannot get this to work where it is needed to first read
> the first attribute and then all attributes of the child and then
> back to reading the second attribute of the parent element. Also how
> to keep track of next items by restricting count of rows per 
> table to just
> 4.

You can get the elements in groups of four and restart your table or page
based upon that easily enough, q.v. --

http://www.dpawson.co.uk/xsl/sect2/N4486.html#d5052e727

What you cannot do, as several others have pointed out, is process
attributes in a fashion dependent upon ordering.  Attributes, by definition,
are unordered.

This is one of the few constraints that make a clear choice between elements
and attributes in designing an XML data structure.  If you want your
processing to be influenced by the order of a set of datapoints, you must
make them element children rather than attributes.

HTH,

Mike


-----------------------------------
Mike Haarman,
XSL Developer,
Internet Broadcasting Systems, Inc.

Current Thread