<!-- 下面定义的这个iframe是为了解决弹出的窗口会被OCX控件挡住的问题 -->
<iframe id="top_iframe" style="position:absolute;z-index:9;display:none;
width:expression(this.nextSibling.offsetWidth);
height:expression(this.nextSibling.offsetHeight);
top:expression(this.nextSibling.offsetTop);
left:expression(this.nextSibling.offsetLeft);"
frameborder="0">
</iframe>
<form name="BackhaulForm" action="<%=sPostUrl%>"
style="position:absolute;display:none;z-index:10;" method="post"> </form> 类似上面这样,把form换成你的div就行了,记得设置style中的z-index:10
<iframe id="top_iframe" style="position:absolute;z-index:9;display:none;
width:expression(this.nextSibling.offsetWidth);
height:expression(this.nextSibling.offsetHeight);
top:expression(this.nextSibling.offsetTop);
left:expression(this.nextSibling.offsetLeft);"
frameborder="0">
</iframe>
<form name="BackhaulForm" action="<%=sPostUrl%>"
style="position:absolute;display:none;z-index:10;" method="post"> </form> 类似上面这样,把form换成你的div就行了,记得设置style中的z-index:10
解决方案 »
- JS confirm()对话框,如何让光标默认位置在取消按钮上?
- 如下input里的字怎么让它显示或消失?
- new ActiveXObject("Msxml2.DOMDocument");
- 为什么avi视频不放不了
- 非常简单,弱智题,马上结贴
- 我想在页面用点击一个按钮,弹出一个窗口,在窗口显示一个下载的按钮,在这个窗口里实现下载功能,我改怎么办,高手帮我,加分
- 如何得到第n行单元格的数据
- 触发事件后,按钮开始闪烁?
- 怎样赋值给动态的input对象?我找遍了函数也不成!
- 如何让按钮失效(很菜的问题,实在不好意思问,唉......)
- 这样的功能如何实现?
- 浏览器ie7.0的javascript问题
<iframe style="position:absolute;z-index:-1;width:100%;height:100%;top:0;left:0;scrolling:no;" frameborder="0" src="about:blank"></iframe>
<div style="background-color:#cccccc;">aaaaaaa<br>bbbbbbb<br>ccccccc<br>ccccccc<br>ccccccc<br>ccccccc</div>
</div><select style="width:200" ><option>test0<option>test1<option>test2<option>test3</select>
有的朋友通过把div的内容放入iframe或object里来解决。
可惜这样会破坏页面的结构,互动性不大好。这里采用的方法是:虽说div直接盖不住select
但是div可以盖iframe,而iframe可以盖select,
所以,把一个iframe来当作div的底,
这个div就可以盖住select了.
采用你的方法可以达到select挡住的问题,但是在包含iframe的div在其隐藏的时候也挡住了文本框,这样在用户操作的时候,无法聚焦到文本框上?你有什么好的办法?