我有10个无线电台塔顿/布顿台。 当然,每个纽州都有自己的价值,我想在纽伦被霸占时,在纽托邦旁显示价值。
我如何处理这个问题?
说明:
row1 : radio1.1 radio1.2 radio1.3 print value radio in here when radio is hovered
row2 : radio2.1 radio2.2 radio2.3 print value radio in here when radio is hovered
row3 : radio3.1 radio3.2 radio3.3 print value radio in here when radio is hovered
我利用了<条码>生命功能条码>,从j Query获取活动mouseover
,但我如何将这一数值具体放在特定的行文中?
我怎么能够拿到哪台无线电台,以便我获得其价值?
<!DOCTYPE html>
<html>
<head>
<link href="jslib/jquery_theme/jquery.ui.all.css" rel="stylesheet" type="text/css"/>
<script src="jslib/jquery-1.7.1.min.js"></script>
<script src="jslib/jquery-ui-1.8.18.custom.min.js"></script>
<script>
$(document).ready(function() {
$(".ter").buttonset();
});
$( .ter > label ).live( mouseover mouseout , function(event) {
if (event.type == mouseover ) {
document.getElementById( mydiv ).innerHTML = "Hello World";
//this is when radio is hovered, it should show radio value beside the rwadio
} else {
document.getElementById( mydiv ).innerHTML = "out";
//this is when mouse is out from radio
}
});
$(function() {
$("#radio :radio").change(function(e) {
alert(
"run ok"
);
});
});
</script>
</head>
<body style="font-size:62.5%;">
<div id="radio">
<form name= tes method= post action= a.php >
<?php for($I=0;$I<10;$I++){
echo"
<div class= ter style= border:1px solid; width:400px; margin-bottom:5px; >
<input type= radio id= radio1.$I name= radio.$I value= 4 /><label for= radio1.$I > </label>
<input type= radio id= radio2.$I name= radio.$I checked= checked value= 3 /><label for= radio2.$I > </label>
<input type= radio id= radio3.$I name= radio.$I value= 2 /><label for= radio3.$I > </label>
<input type= radio id= radio4.$I name= radio.$I value= 1 /><label for= radio4.$I > </label>
<span id= mydiv >aaaaaaaaaa</span>
</div> ";
} ?>
<div class= ter >
<input type= submit value = submit >
</div>
</form>
</div>
</body>
</html>