How can I make a form that has a box of text type number, and according to the number that I enter appears groups of text box to fill in that form?
Example:
Text box (number of days) = 4
<div>
<input type="date" name="data[]">
<input type="time" name="hinicio[]">
<input type="time" name="hfim[]">
</div>
<div>
<input type="date" name="data[]">
<input type="time" name="hinicio[]">
<input type="time" name="hfim[]">
</div>
<div>
<input type="date" name="data[]">
<input type="time" name="hinicio[]">
<input type="time" name="hfim[]">
</div>
<div>
<input type="date" name="data[]">
<input type="time" name="hinicio[]">
<input type="time" name="hfim[]">
</div>
Another example:
Text box (number of days) = 1
<div>
<input type="date" name="data[]">
<input type="time" name="hinicio[]">
<input type="time" name="hfim[]">
<div>
This does not refresh the page, and in the end send all the form inckuido the text box number days I'm working with php (Codeigniter)