Home  >  Article  >  Web Front-end  >  请问display:inline-block有什么不好的地方吗_html/css_WEB-ITnose

请问display:inline-block有什么不好的地方吗_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 12:09:511081browse

如题,用这个属性有什么弊端?谢谢各位了


回复讨论(解决方案)

弊端就是IE6不支持。

你下个CSS文档看看吧,本版精华里有

弊端就是IE6不支持。
++
兼容问题

可以这么做
    div{ display:inline-block; background:#000; width:100px;height:100px}
div{_display:inline;}

1111
2222

每个属性值都是有用的,只是看你用的地方合适与否;没有绝对的所谓的弊端,至于兼容问题这说是弊端有些勉强,完全可以通过hack搞定,总的来时,我觉得这个属性值是非常有用的。

顺便说下,4楼的兼容方法是不够正确的,正确的方式是:display:inline-block;*display:inline;*zoom:1

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn