回归: css, bug bug, backgroundrepeat and frames

2008-07-16 11:59
翻译一段话,关于IE这个大流氓软件的一个bug,没找到用中文描述同样问题的资料,好在俺也学过十年八年E文。
标题: IE6 bug: background-repeat and frames
问题:你有没有碰到过这样的bug(如你所知我正为此事发大愁),在为页面body应用样式background-repeat repeat-x or repeat-y的时候,如果页面是在frame中,IE6将不能正确的渲染页面,从而页面变得几乎无法阅读(上帝保佑,我遇到的情况仅是页面有点乱,但已经足够让我十分恼火),这个bug的玉帛金身,往往在页面没加载完成的时候大驾光临,至少在你使用滚动条的时候总会出现。
我是在用hotmail帐号发送一个链接的时候发现这个问题的,该死的hotmail在一个frameset窗口中打开这个链接,结果让人极度的不爽。
我的css是这么写的:
body{
            background-image: url(../images/topgradientgrey.gif);
            background-repeat: repeat-x;
}
在IE6 and windows XP环境下,你可以在这个链接中亲眼目睹此bug的风采:http://www.interquess.com/test/ 
在opera和gecko(firefox)中不存在这样的问题。

解决方法很简单,后面一跟贴中写到:Having background-color as well does the trick...
也就是说,同时应用background-color样式就一切OK了:
body{ background-color: #fff; background-image:url(bgimage.gif); background-repeat: repeat-x; }


写到这里的时候,感觉自己已经做好改行当一个页面制作的superstar的准备了。

From:
http://fallgoldwls.spaces.live.com/Blog/cns!308336F133D19F06!332.entry

原文地址:https://www.cnblogs.com/qingyun163/p/2365590.html