日期:2014-05-16 浏览次数:20524 次
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>
<span id="A1">16.39</span><br />
<br />
<span id="A2">11239</span>
<br />
<span id="Span2">112239</span>
</div><span id="Span1">116.39</span><br />
</form>
</body>
<script type="text/javascript">
var obj = document.getElementsByTagName("span");
for (var i = 0; i < obj.length; i++) {
var span = document.getElementById(obj[i].id);
span.onmouseover = function() { span.style.color = "#FF9900"; };
span.onmouseout = function() { span.style.color = "#FFFFFF"; };
}
</script>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>
<span id="A1">16.39</span><br />
<br />
<span id="A2">11239</span>
<br />
<span id="Span2">112239</span>
</div><span id="Span1">116.39</span><br />
</form>
</body>
<script type="text/javascript">
var obj = document.getElementsByTagName("span");
for (var i = 0; i < obj.length; i++) {
obj[i].onmouseover = function() { this.style.color = "#FF9900"; };
obj[i].onmouseout = function() { this.style.color = "#FFFFFF"; };
}
</script>
</html>