473,466 Members | 1,639 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

XSLT: Split into multiple columns

I am wanting to create an HTML table using XSLT that looks like: -

-------------
| A | B | C |
-------------
| D | E | F |
-------------
| G | H | |
-------------

based on some XML that looks like:

<items>
<item>A</item>
<item>B</item>
<item>C</item>
<item>D</item>
<item>E</item>
<item>F</item>
<item>G</item>
<item>H</item>
</items>

.... and (as you can probably guess from the fact I am writing this!) I
can't work out how to do it. Anyone got any ideas?

Many thanks
G
Jul 20 '05 #1
3 4297
http://www.topxml.com/code/default.a...20020514091249
=====
Cheers,

Dimitre Novatchev.
http://fxsl.sourceforge.net/ -- the home of FXSL
"Gary Johnson" <gc********@virgin.net> wrote in message
news:4e**************************@posting.google.c om...
I am wanting to create an HTML table using XSLT that looks like: -

-------------
| A | B | C |
-------------
| D | E | F |
-------------
| G | H | |
-------------

based on some XML that looks like:

<items>
<item>A</item>
<item>B</item>
<item>C</item>
<item>D</item>
<item>E</item>
<item>F</item>
<item>G</item>
<item>H</item>
</items>

... and (as you can probably guess from the fact I am writing this!) I
can't work out how to do it. Anyone got any ideas?

Many thanks
G

Jul 20 '05 #2
> > -------------
| A | B | C |

-------------
| D | E | F |

-------------
| G | H | |
-------------

based on some XML that looks like:

<items>
<item>A</item>
<item>B</item>
<item>C</item>
<item>D</item>
<item>E</item>
<item>F</item>
<item>G</item>
<item>H</item>
</items>

... and (as you can probably guess from the fact I am writing this!) I
can't work out how to do it. Anyone got any ideas?


try with position() or mod() functions
Jul 20 '05 #3
> ... and (as you can probably guess from the fact I am writing this!) I
can't work out how to do it. Anyone got any ideas?


use position() function (and "mod" math function)
Jul 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: LW | last post by:
I'm using the following free implementation of an XSLT "split" function, as a template: http://www.exslt.org/str/functions/split/str.split.template.xsl.html Basically, it allows me to call it...
2
by: sam | last post by:
Hi, I've been buried in xsl and xslt articles for several days now, and am still unsure as to what I need to do... Basically, my vb.net app loads up an XML file from an external source...
2
by: Knighterrant | last post by:
How to combine multiple xml files into a single one, or split an xml file into multiple files using xslt?
3
by: Andy | last post by:
Hi all, I'm having a problem doing an Xslt transform in code. I've done it before, so I'm not really sure why its not working. The problem is that the result of the transform is an empty...
21
by: Damian | last post by:
Hi, I'm from an ASP.NET background an am considering making the switch to Python. I decided to develop my next project in tandem to test the waters and everything is working well, loving the...
1
by: Shrek | last post by:
My xslt file contains a passed parameters <xsl;param name="Widths">70px,70px,70px,100px,100px</xsl;param> which I want to use to sets the widths of my table columns . when I create my...
4
by: Grant Robertson | last post by:
Can an XML Stylesheet Language Transform take data that is spread out in multiple different XML files and not necessarily in proper order, rearrange that data into it's proper order and then...
0
by: miamikk | last post by:
I am XML newbie. I have question about inserting dynamic text in the header of HTML table. This is the site I have created (Only Report Type 1 is working)...
1
by: arulkumara | last post by:
Hi, I have one problem in mysql. how to split single row into multiple columns in mysql. my table structure: id salaryhigh salarymedium salarylow...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.