计数器:点击第一次弹1点击第2次弹2,依次类推
<style>
input{
background-color:pink;
}
</style>
<input id="button" type="button">
<script>
window.οnlοad=function(){
var urm=0;
var bu=document.getElementById('button');//获取id
bu.οnclick=function(){//获取id的点击事件
urm++;//先输出后增加
alert(rum);
}
</script>