Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google Web Fonts

I'm planning to use Google web fonts on my site.
My site has lots of pages, but only a few CSS files.
-=> Is there any way to add this tag in the CSS file (because I don't want to edit all the HTML files)?

<link href=' http://fonts.googleapis.com/css?family=Droid+Sans' rel='stylesheet' type='text/css'>

or do I need to add the above line in every HTML page's head section?

like image 620
Sourav Avatar asked Nov 06 '25 13:11

Sourav


1 Answers

Yep, @import the google font in - jsfiddle example

Put this at the top of your CSS file

@import url('http://fonts.googleapis.com/css?family=Droid+Sans');

Then, reference it like normal

h1 { font-family: 'Droid Sans', arial, serif; font-size:24pt;}
like image 90
Dan F Avatar answered Nov 08 '25 09:11

Dan F



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!