日期:2014-05-16  浏览次数:20379 次

JS代码为什么会提示缺少对象
<script type="text/javascript">
<!--
var whatsNew = open('','_blank','top=50,left=50,width=200,height=300,' +
  'menubar=no,toolbar=no,directories=no,location=no,' +
  'status=no,resizable=no,scrollbars=yes');
whatsNew.document.write('<center><b>更新通知</b></center>');
whatsNew.document.write('<p>最后更新日期:00.08.01');
whatsNew.document.write('<p>00.08.01:增加了“我的最爱”栏目。');
whatsNew.document.write('<p align="right">' +
  '<a href="javascript:self.close()">关闭窗口</a>');
whatsNew.document.close();
-->
</script>


------解决方案--------------------
如果没有拦截设置,是可以的
IE8测试是可以的
<script type="text/javascript">
<!--
var whatsNew = open('','_blank','top=50,left=50,width=200,height=300,' +
'menubar=no,toolbar=no,directories=no,location=no,' +
'status=no,resizable=no,scrollbars=yes');
whatsNew.document.write('<center><b>更新通知</b></center>');
whatsNew.document.write('<p>最后更新日期:00.08.01');
whatsNew.document.write('<p>00.08.01:增加了“我的最爱”栏目。');
whatsNew.document.write('<p align="right">' +
'<a href="javascript:self.close()">关闭窗口</a>');
whatsNew.document.close();
//-->
</script>