<iframe src="http://www.163.com" id="ice"></iframe>
<script type="text/javascript">
document.getElementById("ice").onreadystatechange = function(){
if(this.readyState == 'complete')
alert('complete');
}
</script>
<script type="text/javascript">
document.getElementById("ice").onreadystatechange = function(){
if(this.readyState == 'complete')
alert('complete');
}
</script>
FireFox onreadystatechange
我只是判断是否有加载完成IFRAME。但是即时加载了一个只有几行字的页面,也是没有作用!
onreadystatechange 也是白费心, 在 当前窗口得到 iframe 时, 他的 readstate 执行完了.
现在我想要的东西都弄出来了。OK。结帖,进者有分!
--------------------------------------------------那是你的事件绑定有错了,firefox下事件不是这样绑定的