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

推荐订阅源

Simon Willison's Weblog
Simon Willison's Weblog
Help Net Security
Help Net Security
P
Privacy International News Feed
T
Threat Research - Cisco Blogs
C
Cisco Blogs
C
CERT Recently Published Vulnerability Notes
NISL@THU
NISL@THU
L
LINUX DO - 热门话题
Security Latest
Security Latest
A
Arctic Wolf
G
GRAHAM CLULEY
月光博客
月光博客
S
Securelist
D
Docker
J
Java Code Geeks
T
Troy Hunt's Blog
T
Tenable Blog
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
SecWiki News
SecWiki News
S
Security @ Cisco Blogs
量子位
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
L
LINUX DO - 最新话题
Recent Commits to openclaw:main
Recent Commits to openclaw:main
aimingoo的专栏
aimingoo的专栏
博客园 - 【当耐特】
H
Heimdal Security Blog
The Hacker News
The Hacker News
博客园 - 三生石上(FineUI控件)
Application and Cybersecurity Blog
Application and Cybersecurity Blog
N
Netflix TechBlog - Medium
Vercel News
Vercel News
Forbes - Security
Forbes - Security
B
Blog RSS Feed
H
Hackread – Cybersecurity News, Data Breaches, AI and More
IT之家
IT之家
B
Blog
MongoDB | Blog
MongoDB | Blog
博客园 - 聂微东
Google DeepMind News
Google DeepMind News
S
Secure Thoughts
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
C
Check Point Blog
云风的 BLOG
云风的 BLOG
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
T
The Blog of Author Tim Ferriss
L
Lohrmann on Cybersecurity
F
Full Disclosure
D
Darknet – Hacking Tools, Hacker News & Cyber Security
P
Proofpoint News Feed

博客园 - James_Chen

SEO站内优化(On-page SEO) 一个逗号引发的IE7 Jquery Ajax失效 Chromium书签同步无法连接到服务器的解决办法 jquery ajax 乱码解决 does not contain a definition for 80072745 80072efd 解决办法 FLASH ActionScript2.0 读取WebService数据 实现将dataset已有的一个datatable重新排序(转) ASP.NET程序中常用的三十三种代码 - James_Chen - 博客园 DataGridView 在程序集中找到无效的ServicedComponent派生类。 Cookie常用 - James_Chen - 博客园 regasm regsvcs区别 8004EOOF错误 - James_Chen - 博客园 声明了属性后,可像使用类的字段那样使用这些属性。 - James_Chen - 博客园 给BindingNavigator加个保存按钮 DateSet和BindingNavigator合作的产物 Visual Studio 2005 中的 TableAdapter C#中计算两个时间的差
CSS IE6/IE7/IE8/FireFox CSS 兼容办法 hack - James_Chen
James_Chen · 2010-09-04 · via 博客园 - James_Chen

CSS之IE8兼容方法+兼容IE6/IE7/IE8/FireFox的CSS hack

IE8正式版推出以来,有些没有按照标准来写代码的页面,可能会存在兼容问题,下面介绍几种兼容的办法:

一、通过hack兼容

"\9" 例:"font-size:16px\9;".这里的"\9"可以区别所有IE 和 FireFox.

"*" IE6IE7可以识别.IE8FireFox不能.

"_" IE6可以识别"_",IE7IE8FireFox不能.

可能这样写不是很理解,举个例子:

font-size:16px;         /*所有浏览器都适用*/

font-size:14px\9;      /*IE6、IE7、IE8*/

*font-size:18px;        /*IE6、IE7*/

_font-size:20px;       /*IE6*/

二、通过IE8兼容视图来兼容

在html代码的head部分加入以下代码:

<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />

补充一个chRome 的hack

body:nth-of-type(1) classname{}