Setting up Favicons in IE8, Firefox, Safari, and Opera
Firefox(+Camino), Safari, and Opera:
These browsers are easy to setup and only require a 16×16 image file (png, jpg, or gif) and a link tag in the head tag of your code.
1 | <link rel="icon" type="image/png" href="/favicon.png" /> |
IE automaticaly checks the root directory for a file called favicon.ico, so thats where I recommend placing your image. (/favicon.ico)
You don’t need any link code snippet to make this work, but if you wanted to force IE to find it and or change it for another page you can use the following link code in the head tag.
1 | <link href="/favicon.ico" type="image/x-icon" rel="shortcut icon" /> |
I wrap this code with an IE conditional comment. Although the other browsers recognize this code, it’s not correct if your trying to produce accurate XHTML, because of the space in “shortcut icon”.
1 2 3 | <!--[if IE]> <link href="/favicon.ico" type="image/x-icon" rel="shortcut icon" /> <![endif]--> |
摘自:http://greghostetler.com/2009/02/setting-up-favicons/
mark一下,偷懒,没翻译,童鞋们基本上都知道的,IE这家伙总是喜欢搞特殊。。。。。。。。



![wordpress 3.1到3.1.1手动升级文件[下载]](http://static.ihacklog.com/wp-files/2011/04/WordPress-3.1upgradeto3.1.1-150x150.png)





好吧,我翻译一下,转走了。。
用到的很少。
就用了统一的代码,没进行浏览器区别、