Horje
js check if radio button is checked Code Example
check if radio button is checked
$('#element').click(function() {
   if($('#radio_button').is(':checked')) { alert("it's checked"); }
});
javascript check radio button
// Native JS solution:
document.getElementById("_1234").checked = true;
// JQuery solution:
$("#_1234").prop("checked", true);
js check if radio button is checked
if(document.getElementById('gender_Male').checked) {
  //Male radio button is checked
}else if(document.getElementById('gender_Female').checked) {
  //Female radio button is checked
}
javascript radio button value if checked
//alert(document.querySelector('input[name = "comp"]:checked').value);

$test=document.querySelector('input[name = "comp"]:checked').value;

if($test="silver") {
        amount=50;
    }else if($test="gold") {
      amount=90;
    }else{
      amount=30;
    }




Javascript

Related
onclick checkbox hide div and unchecked show div Code Example onclick checkbox hide div and unchecked show div Code Example
how to set/get cookie in JavaScript Code Example how to set/get cookie in JavaScript Code Example
create label dynamically in javascript Code Example create label dynamically in javascript Code Example
resize image react native Code Example resize image react native Code Example
how to save cookie in JavaScript Code Example how to save cookie in JavaScript Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
11