自己碰到过的,但是不知道是否是一个广泛的小问题。
<div id="aa"></a>
<script language="javascript">
function testme(obj)
{
alert(obj);
}
</script>
测试一
<script language="javascript">
$("#aa").html="<a href='javascript:testme(this)'>Hello</a>";
</script>
这种写法,好像拿不到object。
测试二
<script language="javascript">
$("#aa").html="<a href='javascript:void(0)' onclick='testme(this)'>Hello</a>";
</script>
这种写法,可以拿到object。