最近在使用POPUP的时候不小心发现一个问题,在POPUP中的inerHTML如果是隐藏的话,那么里边调用外部的FUNCTION不需要加parent。如:
<DIV STYLE="position:relative; top:0; left:0; border:1px solid #424142; border-top:1px solid #cccccc; border-left:1px solid #cccccc; background:#424142; height:20px; width:160px" onContextMenu="return false">
<DIV STYLE="position:relative; top:0; left:0; border:1px solid #424142; border-top:1px solid #cccccc; border-left:1px solid #cccccc; background:#424142; height:20px; width:160px" onContextMenu="return false">
<DIV ID="firstrunKey0" STYLE="display:none;" οnclick="edit('gys_addkj.asp?gysid=[index0]',600,400,window.location.href);">FirstRun</DIV>
<DIV STYLE="position:relative; top:0; left:0; background:#FFFBF7; border-right:1px solid #848284; border-top: 1px solid white; border-left:1px solid white; border-bottom:1px solid #eeeeee; height:20px; color:black; font-family:verdana; padding:2px; padding-left:10px; font-size:8pt; cursor:hand" οnmοuseοver="this.style.background='#B5BACE'" οnmοuseοut="this.style.background='#FFFBF7'" οnclick="parent.rmopo.hide();parent.edit('gys_addkj.asp?gysid=',600,400,parent.location.href);" onContextMenu="return false">
添加记录</DIV>
</DIV>
</DIV>