K
K
kirigosh2014-11-13 21:10:42
css
kirigosh, 2014-11-13 21:10:42

How to make open sans work without internet?

Hello. Tell me how to make the open sans font work without the Internet and google fonts. I have the font on my PC, but when you write the code font: 45px 'Open Sans'; (I also tried without quotes, font-style also wrote), the browser ignores you. As soon as I add a line from google font, everything works as if nothing had happened. As soon as I turn off the Internet, the font flies again.

Answer the question

In order to leave comments, you need to log in

4 answer(s)
A
andreloster, 2014-11-13
@andreloster

Studio code.
Downloading a font is not related to the Internet, but only on whether the user has this font in the system or not. If not, implement either with svg or @font-face.

L
Lorem Ipsum, 2014-11-13
@GeorgeGeorge

at the beginning of the css file:

@font-face {
    font-family:  Open Sans; /* Имя шрифта */
    src: url(fonts/open_sans.ttf); /* Путь к файлу со шрифтом */
   }

K
kirigosh, 2014-11-13
@kirigosh

Thank you! Problem solved!

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question