日期:2014-05-16  浏览次数:20334 次

请问javascript的鼠标进过的问题
<html>
<head>
<script   language= "javascript ">
window.onload=function   aa()
(
  var   nam=document.getElementById( "lpdiv ")
  nam.onmouseover=a
)
function   a()
(
window.alert( 'aaa ')
)
</script>
</head>
<body>
<div   id= "lpdiv "> </div>
</body>
</html>
先谢谢了

------解决方案--------------------
<html>
<head>
<script language= "javascript ">
window.onload=function(){
var nam=document.getElementById( "lpdiv ")
nam.onmouseover=window.a;
};
function a()
{
window.alert( 'aaa ');
};
</script>
</head>
<body>
<div id= "lpdiv "> here </div>
</body>
</html>