body form method post action input type radio name value id btn_1 div

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<body>
<form method="post" action="">
<input type="radio" name="a" value="1" id="btn_1"/>
<div style="visibility:hidden">
<input type="radio" name="a" value="0" id="btn_2" selected="selected"/>
</div>
<input type="submit" />
</form>
<script src="jquery.js" type="text/javascript"></script>
<script type="text/javascript">
$(document).ready(
function() {
var s = false;
$("#btn_1").click(
function() {
s = !s;
if (!s) {
$('#btn_2').click();
}
}
);
}
);
</script>
</body>