Hello all,
I have a list of categories and Item and I have to divide the whole list in
to 3 columns.
Every column should start with category name and no category should exceed
with more than 10 items.
My sample XML is
<Concepts>
<DetailList Category="CATEGORY 1">
<Item>1</Item>
<Item>2</Item>
<Item>3</Item>
.
.
.
<Item>11</Item>
<Item>12</Item>
</DetailList>
<DetailList Category="CATEGORY 2">
<Item>A</Item>
<Item>B</Item>
.
.
<Item>F</Item>
</DetailList>
<DetailList Category="CATEGORY 3">
<Item>item1</Item>
<Item>item2</Item>
<Item>item3</Item>
<Item>item4</Item>
<Item>item5</Item>
<Item>item6</Item>
<Item>item7</Item>
</DetailList>
<DetailList Category="CATEGORY 4">
<Item>USA</Item>
<Item>Canada </Item>
<Item>Brazil</Item>
</DetailList>
<DetailList Category="CATEGORY 5">
<Item> Government </Item>
</DetailList>
<DetailList Category="CATEGORY 6">
<Item>item1</Item>
<Item>item2</Item>
<Item>item3</Item>
.
.
<Item>item14</Item>
<Item>item15</Item>
</DetailList>
<DetailList Category="CATEGORY 7">
<Item>Minnesota</Item>
<Item>New Jersey</Item>
<Item>New Mexico</Item>
<Item>South Carolina</Item>
</DetailList>
</Concepts>
Sample HTML Table
===========
Column 1
===========
CATEGORY 1
1
2
3
4
5
6
7
8
9
10
CATEGORY 2
A
B
C
D
E
F
===========
Column 2
===========
CATEGORY 3
Item1
Item2
Item3
Item4
Item5
Item6
Item7
CATEGORY 4
USA
CANADA
Brazil
CATEGORY 5
Government
===========
Column 3
===========
CATEGORY 6
item1
item2
item3
item4
item5
item6
item7
item8
item9
item10
CATEGORY 7
Minnesota
New Jersey
New Mexico
South CarolinaHere I have not started CATEGORY 6 below CATEGORY 5
because all the 'items' inside that Category will not fit in to the second
column.There can be any number of categories and items.
I was able to generate the list of all the categories and
list but not sure how to divide them into three columns.
Please let me know how should I proceed.
Thanks,
Shashank Jain
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--