I am a begginer in javascript and I have a set of checkbox inputs interchanging with a set of textbox inputs in my html form. The purpouse of a check box is to identify which texpoxes are printed and which are not.
Example:
<form>
<input type='checkbox' name='one'>
<input type="text" name="one"><br>
<input type='checkbox' name='two'>
<input type="text" name="two"><br>
<input type='checkbox' name='three'>
<input type="text" name="three"><br>
<input type='checkbox' name='four'>
<input type="text" name="four"><br>
</form>
so i need a small javascript example on what would be the best way to print only text from text boxes where the checkbox is checked?
Aucun commentaire:
Enregistrer un commentaire