亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定

請問這樣子為什么不能觸發鼠標事件?

<!DOCTYPE HTML>

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>鼠標移開事件 </title>

<script type="text/javascript">

? var name=document.getElementById("first");


? name.onmouseout=function(){

? ? ? alert("相信我,frighting");

? }

</script>

</head>

<body>

<form id="first">

? <a href="http://www.xianlaiwan.cn">點擊我</a>

</form>

</body>

</html>


正在回答

3 回答

<!DOCTYPE HTML>

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>鼠標移開事件 </title>

<script type="text/javascript">

? function message(){

? ? alert("不要移開,點擊后進行慕課網!"); }

</script>

</head>

<body>

<form>

? <a href="http://www.xianlaiwan.cn" onmouseout="message()">點擊我</a>

</form>

</body>

</html>


0 回復 有任何疑惑可以回復我~

<!DOCTYPE HTML>

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>鼠標移開事件 </title>

<script type="text/javascript">

window.onload = function() {

var name = document.getElementById("first");

name.onmouseout = function () {

alert("相信我,frighting");

}

}

</script>

</head>

<body>

<form id="first">

<a href="http://www.xianlaiwan.cn">點擊我</a>

</form>

</body>

</html>


1 回復 有任何疑惑可以回復我~

1111

0 回復 有任何疑惑可以回復我~

舉報

0/150
提交
取消

請問這樣子為什么不能觸發鼠標事件?

我要回答 關注問題
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號