Answers for "change radio button css"

3

change radio button color

input[type='radio'] {
  -webkit-appearance:none;
  width:20px;
  height:20px;
  border:1px solid darkgray;
  border-radius:50%;
  outline:none;
  box-shadow:0 0 5px 0px gray inset;
}

input[type='radio']:hover {
  box-shadow:0 0 5px 0px orange inset;
}

input[type='radio']:before {
  content:'';
  display:block;
  width:60%;
  height:60%;
  margin: 20% auto;    
  border-radius:50%;    
}
input[type='radio']:checked:before {
  background:green;
}
Posted by: Guest on January-29-2021
3

radio buttons

<input type="radio" id="male" name="gender" value="male">
<label for="male">Male</label><br>
<input type="radio" id="female" name="gender" value="female">
<label for="female">Female</label><br>
<input type="radio" id="other" name="gender" value="other">
<label for="other">Other</label>
Posted by: Guest on September-21-2020
0

css change radio button style

.radiobutton{
	background-color: cyan;
  	border: none;
  	padding: 2px;
}

.radiobutton:hover{
	background-color: blue;
  	border: none;
  	padding: 10px;
}
Posted by: Guest on July-23-2021

Browse Popular Code Answers by Language