PDA

View Full Version : Using custom fonts in Dreamweaver


macaddict
07-13-2013, 01:28 PM
Hi all

I'm building my final site for my web design course exam but having looked at other sites around the web they're using fonts that are not part of the normal standard.
I've read that by putting some code into the header in CSS that you could use a custom font (as long as it's loaded to the server hosting the website) that will load before the actual site loads so everything looks as intended.

Hope this makes sense, still getting used to CSS.

Many thanks in advance if anyone can advise on this.

edbr
07-14-2013, 01:50 AM
you can embed a font by uploading it to your server and using

@font-face
{
font-family: myFirstFont;
src: url('Sansation_Light.ttf'),
url('Sansation_Light.eot'); /* IE9 */


or
@import url(http://fonts.googleapis.com/css?family=Lato:300,400,700);

to use a font supplied by somewhere else, in this example google fonts

gentleone
07-14-2013, 05:51 PM
http://www.fontsquirrel.com/







...

macaddict
07-14-2013, 08:40 PM
Thanks for your replies guys, would I copy this into my style sheet that I've attached to my site?

edbr
07-15-2013, 01:20 AM
yes you can

domedia
07-15-2013, 07:16 PM
Gentleone do you prefer fontsquirrel?

gentleone
07-15-2013, 09:01 PM
Gentleone do you prefer fontsquirrel?
I don't like a service like Google Fonts cause it relies on JavaScript to load in the fonts from their server. It's also 1 extra HTTP request for each font if you do it like that and therefore I prefer to load it from my own or the clients' server. And Fontsquirrels' webfont generator is very useful to me.