i have some radio buttons :
<input type="radio" id="rdoLevel" name="rdoSelect" />
<input type="radio" id="rdoBase" name="rdoSelect" />
<input type="radio" id="rdoSchool" name="rdoSelect" />
<input type="radio" id="rdoTypeRegistre" name="rdoSelect" />
and i want to check each item by id,for example i want to check if rdoLevel equal checked some code perform
for example like this :
$("input:radio").click(function () {
var id = $(this).attr("id");
if (id == "rdoLevel") {
//some code
}
});
how can i do this?
thanks in your advise!
1 Answer