9

クライアントのカスタム フォント フェイスを IE8 で表示するのに問題があります。IE 9 と 7、および Chrome obv に表示されます。この 1 つのバージョンの IE で問題が発生する理由がわかりません。これが私のhtmlのインクルードステートメントです

<!--[if IE 8]>
    <link rel="stylesheet" type="text/css" href="../styles/ie/cherokee_ie.css" />
    <![endif]-->

そして、これがcherokee_ie.cssファイルです

@font-face {
font-family: 'cherokee';
src: url('../../custom.eot');
src: url('../../custom.eot') format('embedded-opentype'),
src: local('☺'), url('../../font/custom.woff') format('woff'), url('../../font/custom.ttf')             format('truetype'), url('../../font/custom.svg') format('svg');
font-weight: normal;
font-style: normal;
}

h1 ul li {
  font-family:cherokee;
}

src: local のスマイリーフェイスが何をしているのかよくわかりませんが、別の SO の質問でこのコードを見つけたので、IE7 で完全に動作しました (または、少なくとも BrowserLab で確認できる限り)。

また、Browserlab よりも高速にビューを生成する方法はありますか?

4

1 に答える 1

4

IE Con​​ditional を削除し、これを CSS に入れます

@font-face {
    font-family: 'cherokee';
    src: url('../../custom.eot');
    src: url('../../custom.eot?#iefix') format('embedded-opentype'),
         url('../../font/custom.woff') format('woff'),
         url('../../font/custom.ttf') format('truetype'),
         url('../../font/custom.svg#cherokee') format('svg');
    font-weight: normal;
    font-style: normal;

}

そのようなカスタムフォントフェイスフォントにも「...」を使用します

h1 ul li {
  font: 18px/27px 'cherokee', Arial, sans-serif;
}

また、パスが正しく設定されているかどうかも確認してください。

于 2012-04-23T00:16:05.320 に答える