+ 1
How do I import fonts to my web pages?
Hey, by the question alone... I'm sure you can tell that I am an amateur. hehe but that aside, I'm using Microsoft's code writer to build my first website, but when testing on chrome, I get this Basic generic font that looks crappy and amateurish... I downloaded some neat cool fonts that I like but I don't know how to port them to the site... Any tips? thanks
3 Respostas
+ 1
https://developers.google.com/fonts/docs/getting_started
There you go :)
0
@font-face { font-family: 'MyWebFont'; src: url('webfont.eot'); /* IE9 Compat Modes */ src: url('webfont.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ url('webfont.woff2') format('woff2'), /* Super Modern Browsers */ url('webfont.woff') format('woff'), /* Pretty Modern Browsers */ url('webfont.ttf') format('truetype'), /* Safari, Android, iOS */ url('webfont.svg#svgFontName') format('svg'); /* Legacy iOS */ }
this is the best way to import fonts because most browsers today will support this
source: https://css-tricks.com/snippets/css/using-font-face/
0
thank you for the answers guys. trying them