我有一個myshopify網站,我試圖使用@font-face
顯示字體..但由於某種原因,字體沒有生效..這裏是我的:@ font-face在網站上顯示不正確
字體文件:
@font-face {
font-family: 'LeagueGothicRegular';
src: url('{{ 'League_Gothic-webfont.eot' | asset_url }}');
src: url('{{ 'League_Gothic-webfont.eot?iefix' | asset_url }}') format('embedded-opentype'),
url({{ 'League_Gothic-webfont.woff' | asset_url }}) format('woff'),
url('{{ 'League_Gothic-webfont.ttf' | asset_url }}') format('truetype'),
url('{{ 'League_Gothic-webfont.svg#LeagueGothicRegular' | asset_url }}') format('svg');
font-weight: normal;
font-style: normal;
}
..
#top-menu a{
font-family: 'LeagueGothicRegular', sans-serif;
background-color: #fff;
border-top-left-radius: 5px;
border-top-right-radius: 5px;
color: #000000;
display: inline-block;
font-size: 1.97em;
line-height: 1;
text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3);
padding: 6px 18px;
padding-top: 8px;
text-decoration: none
}
什麼蹦出來? THANKYOU!
謝謝..但唉,沒有解決它.. grrr – user1833002
您的CSS文件保存爲.liquid擴展名?根據[this](http://ecommerce.shopify.com/c/ecommerce-design/t/css-disregards-liquid-tags-115513),Shipify可能需要知道解析文件。 –
是的,唉,這是.. – user1833002