This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: Displaying entries in a table vertically
- To: <xsl-list at lists dot mulberrytech dot com>
- Subject: RE: [xsl] Displaying entries in a table vertically
- From: "Michael Kay" <mhkay at iclway dot co dot uk>
- Date: Wed, 18 Jul 2001 02:42:14 +0100
- Reply-To: xsl-list at lists dot mulberrytech dot com
When displaying entries horizontally, you do
<xsl:for-each select="item[position() mod $n = 1]">
<xsl:for-each select=". | following-sibling::item[position() < $n]"
For a vertical display, you just need to change the selection conditions to
something like
<xsl:for-each select="item[position() <= $n]"
<xsl:for-each select=". | following-sibling::item[position() mod $n = 0]">
Not tested and may need minor adjustment.
> -----Original Message-----
> From: owner-xsl-list@lists.mulberrytech.com
> [mailto:owner-xsl-list@lists.mulberrytech.com]On Behalf Of Alan Alda
> Sent: 17 July 2001 22:36
> To: xsl-list@lists.mulberrytech.com
> Subject: [xsl] Displaying entries in a table vertically
>
>
> Hi,
>
> I am writing an XSL sheet which produces an HTML table
> using some entries (which are sorted by my XSL before
> displaying) of an XML file. Pretty straightforward...
>
> The problem is that the specifications doc. that I
> have, requires me to display the entries in the table
> sorted in a vertical fashion.
>
> This means that the spec. requires the entries to be
> like:
> A P U
> B Q V
> C R
>
> whereas, since I am outputting the entries row-wise, I
> am getting the output:
> A B C
> P Q R
> U V
>
> Is there any way I can display the entries sorted in a
> vertical fashion in the table using my XSL sheet?
>
> Thanks,
> Cheers,
> Alan.
>
>
> __________________________________________________
> Do You Yahoo!?
> Get personalized email addresses from Yahoo! Mail
> http://personal.mail.yahoo.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