mar*_*cho 6 internet-explorer-7 mime-types font-awesome
IE7上没有显示字体真棒图标.他们在IE8,IE9,FF和Chrome上运行.
示例HTML:
<span rel="tooltip" data-placement="top" data-original-title="Click to add question to favorites">
<i class="icon-star-empty"></i>
</span>
Run Code Online (Sandbox Code Playgroud)
文件包括:
<link href="/css/bootstrap.css" rel="stylesheet">
<link href="/css/font-awesome.css" rel="stylesheet">
<link href="/css/font-awesome-ie7.css">
Run Code Online (Sandbox Code Playgroud)
请求.woff:
Request:
URL:http://example.com/font/fontawesome-webfont.woff
Response:
Accept-Ranges:bytes
Connection:Keep-Alive
Content-Length:41752
Content-Type:application/octet-stream
Date:Tue, 11 Dec 2012 11:31:51 GMT
ETag:"4095e-a318-4cf1d75fb20dd"
Keep-Alive:timeout=5, max=98
Last-Modified:Thu, 22 Nov 2012 23:02:27 GMT Server:Apache/2.2.22 (Ubuntu)
Run Code Online (Sandbox Code Playgroud)
我在Apache的/etc/apache2/mods-enabled/mime.conf上配置了这个(并重新启动了Apache):
AddType application/octet-stream .woff
Run Code Online (Sandbox Code Playgroud)
我错过了任何配置吗?
Dav*_*ass 16
快速更新此线程.
FontAwesome不再支持IE7,但如果您处于不幸的情况,您需要支持它,因为您需要支持专有软件,我不会提及的名称,包括它作为唯一的浏览器,并拒绝升级,即使在这篇文章发表时,IE8已经推出了近4年,我们现在正在使用IE11,然后像我一样做:
下载ie7.min.css文件并添加上面答案中指示的部分:
打开ie7.min.css文件并将所有".icon-"更改为".fa-",因为FontAwesome已更改其命名约定.
这将使您获得FA 4.0.3的大约95%图标的支持(旧的ie7.min.css文件不支持新引入的字体.
更好地使用IE7条件注释,因此文件仅在IE7中加载.(摘自Fontawesome示例)
<link rel="stylesheet" media="all" href="assets/css/your-icons.css" />
<!--[if IE 7]>
<link rel="stylesheet" media="all" href="assets/css/your-icons-ie7.min.css" />
<![endif]-->
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
12488 次 |
| 最近记录: |