Skip to content
Grav 2.1 is out: every page speaks Markdown. Read the announcement →

Grav CMS links in css

Started by Will Tran 8 years ago · 0 replies · 728 views
8 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 complanar, 6 days ago
6 147 20 hours ago
Support · by Rick Beebe, 6 days ago
2 103 3 days ago
Support · by blu3prince, 3 days ago
0 55 3 days ago
Support · by alex, 4 days ago
2 96 3 days ago
Support · by Marcel, 2 weeks ago
1 146 4 days ago