Last active
December 10, 2015 21:18
-
-
Save mateusreis/4494227 to your computer and use it in GitHub Desktop.
Default form.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<form action=""> | |
<!-- Label and text input --> | |
<label for="regularInput">Regular Input</label> | |
<input type="text" id="regularInput" required /> | |
<!-- Label and Email input --> | |
<label for="emailInput">Email Input</label> | |
<input type="email" id="emailInput" /> | |
<!-- Label and Password input --> | |
<label for="passwordInput">Password Input</label> | |
<input type="password" id="passwordInput" /> | |
<legend>Legend Password Input</legend> | |
<!-- Label and textarea --> | |
<label for="regularTextarea">Regular Textarea</label> | |
<textarea id="regularTextarea"></textarea> | |
<legend>Legend Regular Textarea</legend> | |
<!-- Label and select list --> | |
<label for="selectList">Select List</label> | |
<select id="selectList"> | |
<option value="Option 1">Option 1</option> | |
<option value="Option 2">Option 2</option> | |
<option value="Option 3">Option 3</option> | |
</select> | |
<!-- Wrap checkbox/radio button groups in fieldsets --> | |
<fieldset> | |
<!-- Give the fieldset a label --> | |
<label for="">Checkboxes</label> | |
<!-- Wrap each checkbox in a label, then give it the input and span for the text option --> | |
<label for="regularCheckbox"> | |
<input type="checkbox" id="regularCheckbox" value="checkbox 1" /> | |
<span>Regular Checkbox</span> | |
</label> | |
<label for="secondRegularCheckbox"> | |
<input type="checkbox" id="secondRegularCheckbox" value="checkbox 2" /> | |
<span>Regular Checkbox</span> | |
</label> | |
</fieldset> | |
<fieldset> | |
<label for="">Radio Buttons</label> | |
<label for="regularRadio"> | |
<input type="radio" name="radios" id="regularRadio" value="radio 1" /> | |
<span>Regular Radio</span> | |
</label> | |
<label for="secondRegularRadio"> | |
<input type="radio" name="radios" id="secondRegularRadio" value="radio 2" /> | |
<span>Regular Radio</span> | |
</label> | |
</fieldset> | |
<input type="submit" value="Submit" class="button"> | |
</form> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment