我有一个带有 onclick 参数的 div:
<div onclick="some_function()"></div>
如何访问函数内的事件对象?我需要它来获取 event.target
function some_function()
{
event = event || window.event;
var target = event.target || event.srcElement;
//does not work in IE and Firefox, but works in chrome
}