[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Two column HTML output

Subject: Two column HTML output
From: "David Whipple" <dwhipple@xxxxxxxx>
Date: Thu, 11 May 2000 09:35:28 -0400
two column html
I have a problem I am not able to figure out.

I have a simple xml file:

<result>
  <row>
     <item>aaaa</item>
     <item>bbbb</item>
     <item>cccc</item>
     <item>dddd</item>
     <item>eeee</item>
              ...
  </row>
</result>

with an arbitrary number of item's.

I want to product HTML output like:

<table>
    <tr>
        <td>
            aaaa
         </td>
        <td>
            bbbb
         </td>
    </tr>
    <tr>
        <td>
            cccc
         </td>
        <td>
            dddd
         </td>
    <tr>
 ...
</table>

(put two <item>s in each <tr> </tr> block).  It is easy enough to put
out each item surrounded by <tr> </tr>.  Because of the necessity to
output proper XML, I am not able to read in the <item>s and if it is in
an odd position emit the <tr> and if it is even position emit the </tr>.

Maybe there is some concept I am not aware of/understand that
I am missing here.

Can anyone help me with an approach to dealing with this kind of
problem?


Thanks,
Dave



 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.