I have a form that provides some input boxes and a link with text "Add more". Clicking on the link repeatedly adds the input boxes.
This is my code:
<div class="col-md-2" id="repeatDiv">
<label for="total" class="control-label sr_only"><?php echo lang('total_label'); ?></label>
<?php echo form_input('total',set_value('total'), 'id="total" class="form-control col-md- 4"'.'placeholder='.'"'.lang('placeholder_total').'"'."'");?>
<?php echo form_error('total'); ?>
</div>
<button class="col-md-offset-2 btn btn-primary" id="addmore"><?php echo lang('add_more_btn'); ? />
I want this code to be repeated when a button or the link with text "add more" is clicked.