惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

www.infosecurity-magazine.com
www.infosecurity-magazine.com
D
DataBreaches.Net
T
Tailwind CSS Blog
M
MIT News - Artificial intelligence
Stack Overflow Blog
Stack Overflow Blog
F
Full Disclosure
V2EX - 技术
V2EX - 技术
N
News and Events Feed by Topic
Help Net Security
Help Net Security
L
LangChain Blog
Y
Y Combinator Blog
宝玉的分享
宝玉的分享
Google Online Security Blog
Google Online Security Blog
P
Proofpoint News Feed
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
T
The Blog of Author Tim Ferriss
Google DeepMind News
Google DeepMind News
The Register - Security
The Register - Security
B
Blog RSS Feed
N
Netflix TechBlog - Medium
N
News | PayPal Newsroom
TaoSecurity Blog
TaoSecurity Blog
酷 壳 – CoolShell
酷 壳 – CoolShell
V
Vulnerabilities – Threatpost
B
Blog
C
Cyber Attacks, Cyber Crime and Cyber Security
I
Intezer
H
Hackread – Cybersecurity News, Data Breaches, AI and More
博客园_首页
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
AI
AI
aimingoo的专栏
aimingoo的专栏
大猫的无限游戏
大猫的无限游戏
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Cyberwarzone
Cyberwarzone
P
Proofpoint News Feed
Google DeepMind News
Google DeepMind News
G
GRAHAM CLULEY
Vercel News
Vercel News
罗磊的独立博客
MyScale Blog
MyScale Blog
Last Week in AI
Last Week in AI
博客园 - 司徒正美
C
CERT Recently Published Vulnerability Notes
GbyAI
GbyAI
Scott Helme
Scott Helme
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
T
Troy Hunt's Blog
A
About on SuperTechFans
P
Privacy International News Feed

博客园 - 爽爽

印章规格(2) 巧妙自制ps笔刷 当float遇到clear和clip 网站变黑白灰色的4种代码(转载) 15个CSS常识 CSS网页布局编码小技巧整理(转帖资料) word-break:break-all和word-wrap:break-word 自动换行问题 兼容IE6/IE7/IE8/FireFox的CSS hack - 爽爽 - 博客园 网页设计师的苦衷 ul li实现table - 爽爽 - 博客园 基于栅格系统的web设计——灵与魂的融合 [欣赏] 2008年logo设计趋势 出水芙蓉——网页中的广告位 汗~注释也能影响兼容?!—css中遇到的变态问题 常用图片格式全解(收藏~转) 网页设计标准尺寸(文章很实用~转) 我拿青春赌明天!后果我自负~ 什么教学海无涯! 继续学习adobe Illustrator之泡泡字体
IE下神奇的一个Bug!
爽爽 · 2009-12-25 · via 博客园 - 爽爽

不罗嗦,直接上内容

IE 下块元素如何实现 display:inline-block 的效果?

有两种方法:

1、先使用 display:inline-block 属性触发块元素,然后再定义 display:inline,让块元素呈递为内联对象(两个 display 要先后放在两个 CSS 声明中才有效果,这是 IE 的一个经典 bug,如果先定义了 display:inline-block,然后再将 display 设回 inline 或 block,layout 不会消失)。代码如下(...为省略的其他属性内容):

div {display:inline-block;...}
div {display:inline;}

Steven(21887396)  15:09:56
2、直接让块元素设置为内联对象呈递(设置属性 display:inline),然后触发块元素的 layout(如:zoom:1 等)。代码如下:

div {display:inline; zoom:1;...}

纯粹给div设置inline-block,IE6是不会并排的,以前遇到过这样的情况,当时没有解决,绕道而行啦!为了追求设计之路的发展,基本已经搁置css,由于工作需要接下来要做hc360的n套页面,不得不重新拾来页面制作!本想看看经过近一年的时间web2.0有何新发展....却意外看到了这个解决方法,哈哈,嘿嘿 嘿嘿 呵呵

终于知道为什么有时候实现不了啦!看似简单,解决不了就不简单了!

收藏!