还是那个iframe的问题,高分求救~~

youtiaoya 2005-06-04 12:12:38
<script language=javascript>
function HideObj(Obj)
{
Obj.style.display = "none";
}
function ShowObj(Obj)
{
Obj.style.display = "";
}

</script>
<table id="Tab">
<tr>
<td>这是表格内容</td>
</tr>
</table>
<input type=button onclick="HideObj(window.document.all.Tab);" value="隐藏表格">
<input type=button onclick="ShowObj(window.document.all.Tab);" value="显示表格">


<iframe id=ccc WIDTH=468 HEIGHT=60 align=center MARGINWIDTH=1 Name=ccc MARGINHEIGHT=1 HSPACE=0 FRAMEBORDER=0 SCROLLING=no src="http://ccc.ccc.ccc/index.asp">
</iframe>

现在点击 隐藏表格 就能隐藏了表格内容
我想实现的是点击iframe的内容,也能隐藏表格内容
...全文
83 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
kc_ren 2005-06-04
  • 打赏
  • 举报
回复
这个我不是很清楚 我这里有一个点IFRAME 框就能开启和隐藏的 应该比较实用
<script>
function switchSysBar(){
if (switchPoint.innerText==3){
switchPoint.innerText=4
document.all("frmTitle").style.display="none"
}
else{
switchPoint.innerText=3
document.all("frmTitle").style.display=""
}
}
</script>

<table border="0" cellspacing="0" cellpadding="0" width="100%" height="100%">
<tr>
<td id="frmTitle" name="frmTitle" nowrap valign="middle" align="center">
<IFRAME id="BoardTitle" name="main" style="HEIGHT: 100%; VISIBILITY: inherit; WIDTH: 200; Z-INDEX: 2" scrolling="no" frameborder="0" src=""></IFRAME>

<td style="width:10pt" >

<table cellspacing="0" cellpadding="0" border="0" height="100%">
<tr><td style="height:100%" onclick="switchSysBar()" bgcolor="#0066FF">
<font color="#FFFFFF"><font face="Marlett" size="1"><span class="navPoint" id="switchPoint" title="关闭/打开左栏">3</span></font>
</font>
</table>

</td><td style="width:100%">
<IFRAME id="frmright" name="BoardList" style="HEIGHT: 100%; VISIBILITY: inherit; WIDTH: 100%; Z-INDEX: 1" scrolling="auto" frameborder="0" src=""></IFRAME>
</tr></table>
youtiaoya 2005-06-04
  • 打赏
  • 举报
回复
不行 得是点击iframe里的内容才隐藏

28,406

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧