Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR HTML

radio button required

One input with required attribute is enough.

<form>
  Select Gender:

  <label><input type="radio" name="gender" value="male" required>Male</label>

  <label><input type="radio" name="gender" value="female">Female</label>

  <label><input type="radio" name="gender" value="other">Other</label>

  <input type="submit">
</form>
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #radio #button #required
ADD COMMENT
Topic
Name
5+9 =