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

Using a loop in XSL

Subject: Using a loop in XSL
From: Lars-Arne Mattsson <larssa@xxxxxxxxxx>
Date: Fri, 22 Jan 1999 11:39:24 +0100 (MET)
loop in xsl
Hello!

I only wonder if there is a way to do something like a for-loop in
XSL? I can't find any apropriate commands in the specification so I
ask here.

The thing I want to do is to use a numeric value (N) given as a
attribute and then generate a line of HTML code N number of times.

-- Simple example --------------------
XML:
<question>
  How many of the tests have you taken?
  <alternatives num="3">
</question>

HTML:
<strong>How many of the tests have you taken?</strong>
<input type="radio" name="answer" value=1>
<input type="radio" name="answer" value=2>
<input type="radio" name="answer" value=3>
--------------------------------------

Is this possible, or do I have to generate XML-code for each of the
alternatives?

Greetings, 
/Larssa


 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.