绝对灵异事件!!!
以下代码怎么出错了!!!
<html>
<head>
<title></title>
<script>
function hanshu ( )
{
window.document.anchors[0].style.color = "#ff0000";
window.document.anchors[0].style.text-decoration ="underline";
}
</script>
</head>
<body>
<a href="#" id="a" name="a" style="text-decoration:none; color:#00ff00;" onmouseover="hanshu ( );">aaa</a>
</body>
</html>
以下代码怎么出错了!!!
<html>
<head>
<title></title>
<script>
function hanshu ( )
{
window.document.a.style.color = "#ff0000";
}
</script>
</head>
<body>
<a href="#" id="a" name="a" style="text-decoration:none; color:#00ff00;" onmouseover="hanshu ( );">aaa</a>
</body>
</html>