2 replies [Last post]
martinesko36
martinesko36's picture
Offline
newbie
Last seen: 10 years 3 weeks ago
Timezone: GMT+3
Joined: 2011-08-19
Posts: 2
Points: 3

Hello everybody,
My FontSquirrel generated @font-face is not working. It was working before when it was in zp-base.css, but after a day it stopped working. I have done everything I could. I place @font-face in index.php, but that doesn't fix the things. I'm sure that my path to the fonts is right. The font is not displaying. Here is my code:

	<link rel="stylesheet" href="lib/css/zp-base.css" type="text/css" media="all" />
	<link rel="stylesheet" href="lib/css/zp-compressed.css" type="text/css" media="all" />
	<link rel="stylesheet" href="lib/css/zp-forms.css" type="text/css" media="all" />
	<link rel="stylesheet" href="lib/css/zp-type.css" type="text/css" media="all" />
	<link rel="stylesheet" href="lib/css/zp-ie.css" type="text/css" media="all" />
	<link rel="stylesheet" href="data/navigation.css" type="text/css" media="all" />
	<link rel="Shortcut Icon" type="image/x-icon" href="_img/favicon.ico" />	
	<style type="text/css">
	@font-face {
    font-family: 'HattoriHanzoLight';
    src: url('hattori_hanzo-webfont.eot');
    src: url('hattori_hanzo-webfont.eot?#iefix') format('embedded-opentype'),
         url('hattori_hanzo-webfont.woff') format('woff'),
         url('hattori_hanzo-webfont.ttf') format('truetype'),
         url('hattori_hanzo-webfont.svg#HattoriHanzoLight') format('svg');
    font-weight: normal;
    font-style: normal;
 
}
	</style>
</head>
 
<body style='font-family: HattoriHanzoLight; font-size: 19px; overflow: hidden;'> 

Tyssen
Tyssen's picture
Offline
Moderator
Brisbane
Last seen: 6 years 48 weeks ago
Brisbane
Timezone: GMT+10
Joined: 2004-05-01
Posts: 8201
Points: 1386

Path to fonts

Are you font files in the same directory as your stylesheets? If so, then the URL for your font files should be /lib/css/font_file_name

I also have a feeling that your font-face declaration has to come before the rest of your styles so you should move our style block above everything else.

How to get help
Post a link. If you can't post a link, jsFiddle it.
My blog | My older articles | CSS Reference

martinesko36
martinesko36's picture
Offline
newbie
Last seen: 10 years 3 weeks ago
Timezone: GMT+3
Joined: 2011-08-19
Posts: 2
Points: 3

Well i moved the declaration,

Well i moved the declaration, and check the path - it's right. No change, the font is still not displaying. Someone help. Thanks.
EDIT - It was actually working, but the font does not properly display cirilyc? THe cyrilic was fine for me before. With english words and letters and numbers it works, but with cyrilic no. The font SUPPORT cyrilic.