鼠標經過事件(onmouseover)
任務
補充右邊編輯器第13行,當鼠標經過"確定"按鈕后,調用message()函數,彈出消息對話框。
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title> 鼠標經過事件 </title>
<script type="text/javascript">
function message(){
confirm("請輸入密碼后,再單擊確定!"); }
</script>
</head>
<body>
<form>
密碼:<input name="password" type="password" >
<input name="確定" type="button" value="確定" onmouseover="message()"/>
</form>
</body>
</html>


