<form name="myform" action="" method="" onsubmit="return check()">
<input type="radio" name="picno" value="1">
<input type="radio" name="picno" value="2">
<input type="radio" name="picno" value="3">
<input type="submit" value="Submit">
</form>
<script language="
javascript">
function check(){
var flag=0
for(i=0;i<myform.picno.length;i++)
if(myform.picno[i].
checked==true){ //检测单选按钮状态
flag=1
break
}
if(!flag){
alert("请先选择更换图片的位置")
return false
}
}
</script>