These forums are currently read-only due to receiving more spam than actual discussion. Sorry.

It is currently Sat Dec 02, 2017 4:04 pm Advanced search

How to set initial repetition template index to 1?

Here you can discuss things related to HTML and the Web in general that do not fit in to other categories.

How to set initial repetition template index to 1?

Postby FataL » Thu May 01, 2008 3:37 pm

Here is the cite from Web Forms 2 specification:
Every template has an index associated with it. The initial value of a template's index is always 0.


But I badly need to start counting from 1 instead of 0, because of inability to change a cgi.

That's how I do it for now:
Code: Select all
<div repeat="0" style="display:none"></div>
<div repeat="template" id="myform">
...
<input>
<input>
...
</div>
Is there a better way?
FataL
<h6>
 
Posts: 9
Joined: Thu Jun 28, 2007 7:02 pm

Re: How to set initial repetition template index to 1?

Postby zcorpan » Wed Sep 19, 2012 3:35 pm

Repetition templates have been dropped, so you'll have to implement the functionality in script instead (and data-* attributes if you need custom attributes).
zcorpan
<article>
 
Posts: 807
Joined: Tue Feb 06, 2007 8:29 pm
Location: Sweden


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 1 guest