IE6 重复字符的bug及解决方法
2010-10-25 16:25
323 查看
<div style="width:400px"> <div style="float:left"></div> <!-- --> <input type="hidden" value="hidden" /> <div style="display:none;">hidden</div> <div style="float:left;width:400px">IE6文字溢出的BUG</div> </div> 今天在看一个项目的测试版的时候,发现了IE6文字溢出的BUG,文字出现了“重影”。 开始很快想到的是注释,看了源代码,发现页面里根本没有注释。实在摸不着头脑,祭出了Google,注意到了当初没有注意到的一句话“但IE6的这个重复BUG也有些不是注释造成的,但基本上都和浮动有关系”。后来有查阅到其他文章提到type=hidden的input以及display: none的div也会导致文字溢出的BUG,正好代码有type=hidden的input。 在同事的帮助下(偶E问很烂)查阅了国外的资料,解决了type=hidden的input造成文字溢出的问题。不要把这个input直接放在form下面,可以用div或者fieldset把这个input包起来。 <div style="width:400px"> <div style="float:left"></div> <div><input type="hidden" value="hidden" /></div> <div style="float:left;width:400px">IE6文字溢出的BUG</div> </div> 将文字区块包含在新的div之间,但这个方法对type=hidden的input以及display:none的div不奏效。 <div style="width:400px"> <div style="float:left"></div> <!-- --> <div style="float:left;width:400px"><div>IE6文字溢出的BUG</div></div> </div> 而display:none的div造成的文字溢出同理可以用div将这个隐藏的div包起来。 <div style="width:400px"> <div style="float:left"></div> <div><div style="display:none;">hidden</div></div> <div style="float:left;width:400px">IE6文字溢出的BUG</div> </div> |
相关文章推荐
- IE6出现重复字符的bug解决方法
- ie6 重复字符BUG问题的简单解决方法
- <转>IE6浏览器网页文字溢出的解决办法(重复字符bug)---隐藏float对其他float造成影响
- IE6下最后几个字符重复bug的解决办法
- IE6重复字符BUG
- IE6,IE7,IE8 css bug汇总以及兼容解决方法
- mysql西文字符大小写重复键问题的解决方法
- IE6中用了float:left之后导致margin-left双倍边距的BUG解决方法
- IE6 BUG的解决方法
- ie6,ie7,ie8 css bug兼容解决方法
- IE6背景图片缓存bug解决方法
- IE6中用了float:left之后导致margin-left双倍边距的BUG解决方法
- IE6浏览器的bug问题及相关解决的方法
- IE6、IE7下绝对定位position:absolute和margin的冲突bug解决方法
- IE6重影的解决方法(关于注释引起的文字溢出/3px Bug/双float<浮动>元素字符)
- js,css三种方法解决IE6下position:fixed的Bug以及闪动问题
- jquery的clone方法应用于textarea和select的bug修复不能copy值,clone id重复的解决
- IE6不支持opacity半透明 BUG的解决方法
- 【IE BUG】 CSS/HTML解决在IE6浏览器下显示文字重复
- IE6下的多余字符bug的2种情况和解决办法