javascript获取事件触发源:
<html>
<head>
<title></title>
<script type="text/javascript">
function focusM(ev){
ev = ev || window.event; // 事件
var target = ev.target || ev.srcElement; // 获得事件源
var dragObj = target.getAttribute('id');
alert(dragObj);
}
</script>
</head>
<body>
<input type="text" id="txtTemp" onmouseover="focusM();" />
</body>
</html>