gpt4 book ai didi

jquery - IE6中奇怪的布局问题

转载 作者:行者123 更新时间:2023-12-01 05:08:28 24 4
gpt4 key购买 nike

alt text

网址:http://www.hkpete.com/test.html

jQuery 1.42
jQuery 工具 1.2.3 覆盖

IE7也有这个问题(在ietester上测试)

我找不到问题所在。

非常感谢。

<div id="dialog-content">
<!--Login -->
<div id="login" class="panel" style="display:none">
Login..................
</div>
<!--Register -->
<div id="register" class="panel" style="display:none">
Register..................
</div>
</div>

<!--Links-->
<a href="javascript:;" onclick="showDialog('#login','member');">Login</a>
<a href="javascript:;" onclick="showDialog('#register','member');">Register</a>

<script type="text/javascript">
var ol;
var dialog=null;
function showDialog(panel,action){
var each=each ? each : 0;
function overlay(){
if(panel){
$("#dialog div.panel").hide();
//show panel login,register,lostpw
$(panel).show();
}
if(ol !== undefined && ol.isOpened()) {

$("#dialog").css("top", ( $(window).height() - $("#dialog").height() ) / 2+$(window).scrollTop() + "px");
$("#dialog").css("left", ( $(window).width() - $("#dialog").width() ) / 2+$(window).scrollLeft() + "px");
}

//Overlay load
ol=$("#dialog").overlay({top:'center', left:'center', closeOnClick:false, api:true }).load();

$("#dialog .close").click(function(){
ol.close();
});
}


overlay();
//cur action
dialog=action;

return false;
}
</script>

最佳答案

我想我知道这个错误是什么:http://www.positioniseverything.net/explorer/ienondisappearcontentbugPIE/index.htm .

列出的解决方法是:

Work arounds One may 'release the spell' in a number of ways:

  1. temporarily switch the content's display property to 'block' and back to 'none'.
  2. temporarily switch the content's position property from 'relative' to 'absolute' and back, or vice versa.
  3. temporarily switch the content's visibility property to 'hidden' and back. (But this only works if the content is positioned absolutely! The wonderful world of IE...)

去那里看看以获取更多信息。

关于jquery - IE6中奇怪的布局问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3689725/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com