FRIHOSTFORUMSFAQTOSBLOGSDIRECTORY
You are invited to Log in or Register a Frihost Account!

Change font in headings..

 


ranzon
i'm using this to print a header-text:

Code:
<h1>sometext here</h1>


how can i make something in the css code to use the font: design/font.ttf on <h1> ??

please help.. <3
hexkid
ranzon wrote:
i'm using this to print a header-text:

Code:
<h1>sometext here</h1>


how can i make something in the css code to use the font: design/font.ttf on <h1> ??


I don't think you can.
It certainly would not work for me; I do not have a directory called "design" anywhere on my hard disk.


Read the CSS Fonts page for more info.
ranzon
design is a folder on the webserver.. the font is a specialfont.. i have heard that you can put the font on the webserver, and use it from there.
cavey
You could use php to make a picture with your font: http://no.php.net/imagettftext

Se this article at A List Apart, how to use java script with php to automaticly change all your header-text: http://www.alistapart.com/articles/dynatext
eruct
You may also want to look into this one. It uses Javascript and Flash to display the font you want.

http://www.mikeindustries.com/sifr/
-TomJ-
I have found an article that describes how to create a downloadable font file.
Check it here.
I think it goes in the way you want. At least I did not see any mention of javascripts or the like, as were suggested in this topic.

I would suggest that you define a secondary and a generic font in your css, since not all users may be willing (and/or able) to go through the cumbersome procedure of downloading and installing a font, simply because you want to display your page using your specific font.
flex
Hi,

downloadable fonts are possible, but:
1) there is no official standard. at the moment there are two possible ways, on for ie and one for netscape
2) you have to pay one of the programs (dont remember which one) needed for creating the font (yes - you need the font in an extra format - no ttf)
3) it does not work in all browsers
4) it is so much easier to create a php image if the heading is dynamic. if it is even static, then use an image

greetz
flx
Reply to topic    Frihost Forum Index -> Scripting -> Html, CSS and Javascript

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2007 Frihost, forums powered by phpBB.