December 12, 201213 yr Hi dudes What's for="name" in below code for? <label for="name" class="formlabel">Name</label> <input id="name" name="name" type="text" class="forminput" /> <div class="formwarning">Validation error message</div> Tnx
December 12, 201213 yr It links the label to the form element by it's "name" attribute. This makes the form more accessible, and adds the functionality of clicking the label to focus the form element.
December 17, 201213 yr It links the label to the form element by it's "name" attribute. This makes the form more accessible, and adds the functionality of clicking the label to focus the form element. Actually it's linked by the ID attribute.
Create an account or sign in to comment