1>响应mouseover事件, 弹出对话框“mouse over!”2>响应mouseout事件, 弹出对话框”mouse out!”<html><head><script type="text/javascript">::</script></head> <body><a href="./test1.html" target="_blank"><img border="0" alt="Cannot show this pic." src=./a.jpg" name="pic1"onmouseOver="mouseOver()"onmouseOut="mouseOut()" /></a></body></html>
1 回答
牛魔王的故事
TA贡献1830条经验 获得超3个赞
你的写法基本都是对的,现在只需有用javascript定义两个事件处理函数,并且加上弹出对话框代码就可以了。
<html><head>
<script
type="text/javascript">
function
mouseOver()
{
alert("mouse
over");
}
function
mouseOut()
{
alert("mouse
out");
}
</script>
</head>
<body>
<a
href="./test1.html"
target="_blank"><img
border="0"
alt="Cannot
show
this
pic."
src=./a.jpg"
name="pic1"
onmouseOver="mouseOver()"
onmouseOut="mouseOut()"
/></a>
</body></html>
添加回答
举报
0/150
提交
取消