rendered paste body<script language="JavaScript" type="text/javascript">
function del(formRef) {
var is_check_ok = "no";
for(i=0; i < formRef.id_radio.length; i++){
alert("found id_radio id : " + i);
if (is_check_ok != "yes") {
is_check_ok = (formRef.id_radio[i].checked == true) ? "yes" : "no";
var id = formRef.id_radio[i].value;
} else {
break;
}
}
if (is_check_ok == "no" ) {
alert ("Select at least one item..");
} else {
alert ("debug" + id);
input_box=confirm("Are you sure you want to delete this item ?");
if (input_box==true) {
// location.replace('?a=cd&id='.$id.'');
}
}
}
</script>
<form>
<input type="radio" value="1" name="id_radio"> a <br>
<input type="radio" value="2" name="id_radio"> b <br>
<input type="radio" value="3" name="id_radio"> c <br>
<input type="button" value="delete" onmouseup="javascript:del(this.form);">
</form>