Skip to content
Grav 2.0 is officially stable. Read the announcement →
Support

Grav CMS links in css

Started by Will Tran 7 years ago · 0 replies · 617 views
7 years ago

I have a problem with adding the custom fonts in Grav CMS. All fonts are added under the folder path: user/themes/bildxwerkstatt/fonts

It works on my computer when I'm adding this code in .css file
<code>
@font-face {
font-family: MullerBlack;
src: url(/bildxwerkstatt/user/themes/bildxwerkstatt/fonts/Muller/MullerBlack.otf);}
h1, h2, h3, h4, h5, h6 {
font-family: MullerBlack, sans-serif!important;}
</code>
However on the host such path does not work.

As I understood from the Grav documentation the path to font in css should looks like this:
<code>
url(theme:fonts/Muller/MullerBlack.otf);}
</code>
But it does not work in my case. The same problem I have when trying to add background image in css.

Thank you in advance!

Suggested topics

Topic Participants Replies Views Activity
Support · by kskt, 3 days ago
1 73 4 hours ago
Support · by BenLaKnet, 6 days ago
1 133 3 days ago
Support · by BenLaKnet, 1 week ago
5 200 3 days ago
Support · by David Meissner, 3 days ago
0 60 3 days ago
Support · by David Meissner, 4 days ago
3 104 4 days ago