Subject: [xsl] Formatting in an HTML table...DOWNwise! From: Patrick van Halderen <patrick@xxxxxxxxxxxxx> Date: Wed, 02 Jul 2003 17:13:39 +0200 |
Hi list, I have the following XSLT (well, actually it's a snippet), which formats some data from XML nicely into an HTML table. However, the data is pasted left-to-right, while I'd like it better when it's put up-to-down first. Anyone knows of a solution for this? Thanks in advance! The XSL-snippet: <xsl:template match="modellen"> <table border="1"> <xsl:for-each select="model[position() mod 3 = 1]"> <tr> <xsl:for-each select=".|following-sibling::model[position() < 3 ]"> <td><xsl:apply-templates/></td> </xsl:for-each> </tr> </xsl:for-each> </table> </xsl:template> (For the completeness) Some data: <?xml version="1.0" encoding="ISO-8859-1" ?> <page> <modellen> <model>Lancia Y</model> <model>Lancia Delta</model> <model>Lancia Lybra</model> <model>Lancia k</model> <model>Lancia Zeta</model> <model>Alfa 156</model> <model>Fiat Panda</model> <model>Mercedes CLK</model> </modellen> </page> Greetings, Patrick XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] if statement, Andrew Welch | Thread | Re: [xsl] Formatting in an HTML tab, David Carlisle |
RE: [xsl] xsl:sort in old MSXML, Claudio Russo | Date | RE: [xsl] Dynamic Sort Value Solved, Allistair Crossley |
Month |