Forums

Click to add a new row

Manofstyle 22 Mar, 2012
I'm trying to figure out how to add a "Click to add a new row" so if I have a couple fields that repeat ex. Creditors, debt amount and status these someone could have two lines or ten depending on what they need.
GreyHead 08 Apr, 2012
Hi Manofstyle,

Can you put an upper limit on the number of records to be added? If so then you can create the extra inputs in the form HTML, set them hidden with CSS, then use JavaScript to 'un-hide' a new row when a link is clicked.

If there is no upper limits (or it's more than sey 20 records) then it may be simpler to use JavaScript to create a new set of inputs when needed rather than pre-load a lot of hidden inputs.

Bob
This topic is locked and no more replies can be posted.