我必须使用' helvetica neue'作为我的asp.net默认字体。安装到我的电脑后,我可以将字体添加到我的CSS中,并在本地运行Web应用程序时工作。但是在我部署到服务器之后。 ' helvetica neue'字体不起作用。是否必须在用户计算机上安装该字体?
我的CSS:
@font-face { font-family: Delicious; src: url('../css/Fonts/HelveticaNeueLTPro-CnO.otf'); }
body
{
background: #fff;
color: #333;
/*font-family: HelveticaNeueLT Pro 63 MdEx;*/
font-family: Delicious, sans-serif;
font-size: 76%; /* all font sizes are related to this initial 'small' font-size setting (which is more or less 12pt) */
min-width: 730px; /* min- and max-width don't work in IE Win 6 and below */
max-width: 1250px;
}
答案 0 :(得分:0)
你的@ font-face不完整,还需要更多文件:
您可以在Font Squirrel
创建这些字体文件@font-face {
font-family: 'Delicious';
src: url('../css/Fonts/HelveticaNeueLTPro-CnO.eot');
}
@font-face {
font-family: 'Delicious';
src: url(//:) format('no404'),
url('../css/Fonts/HelveticaNeueLTPro-CnO.woff') format('woff'),
url('../css/Fonts/HelveticaNeueLTPro-CnO.ttf') format('truetype'),
url('../css/Fonts/HelveticaNeueLTPro-CnO.svg#Delicious') format('svg');
font-weight: normal;
font-style: normal;
}