button laert:http://www.w3school.com.cn/tiy/t.asp?f=js_intro_alert

<input type=”button” value=”don’t click me,不信你试试!” onclick=”alert(‘不是告诉你不要点我了吗!你怎么还点啊!’)” />

事件:oumouseover and onclick

————–

<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=utf-8″ />
<title>无标题文档</title>
<style>
#div1 {width:400px; height:30px; background:#FFC}
</style>
<script>
function look1()
{
broszhu1=document.getElementById(“div1″).innerHTML=”github.com/broszhu”;
}
function look2()
{
broszhu2=document.getElementById(“div1″).innerHTML=”点击一下试试吧”;
}
</script>

</head>

<body>
<h1>About Me</h1>
<input type=”button” value=”look me my github” onclick=”look1()” onmouseover=”look2()” />
<div id=”div1″ />
</body>