I am trying to create a xml stylesheet that will end up outputing like so:
The majority of this is easy to work with except for the unique values in for= and id=. I tried to find a good way to increment a value but it doesn't look like it can be done in xsl. Is there any other way i can create these unique values with xsl?
Code:
<li class="alt"><label for="a1"><input id="a1" name="a1" value="xxx" type="checkbox" />xxx</label></li>
<li><label for="a2"><input id="a2" name="a1" value="xxx" type="checkbox" />xxx</label></li>
<li class="alt"><label for="a3"><input id="a3" value="xxx" name="a1" type="checkbox" />xxx</label></li>
<li><label for="a4"><input id="a4" name="a1" value="xxx" type="checkbox" />xxx</label></li>
<li class="alt"><label for="a5"><input id="a5" value="xxx"name="a1" type="checkbox" />xxx</label></li>
<li><label for="a6"><input id="a6" name="a1" value="xxx" type="checkbox" />xxx</label></li>
The majority of this is easy to work with except for the unique values in for= and id=. I tried to find a good way to increment a value but it doesn't look like it can be done in xsl. Is there any other way i can create these unique values with xsl?