Webfonts only load on home page.
-
I’m having trouble with web fonts not loading. They work fine on my home page but don’t load elsewhere. The fonts are locally hosted on the web server. In Chrome the console is showing a 404 error for my web fonts. WordPress is pointing to directories named for each of the site rather than pointing to the top-level web fonts directory.
I’m adding CSS for the fonts using Appearance > Customize > Additional CSS. I’ve tried several themes and this problem occurs with all of them. I also tried using the Simple Custom CSS plugin and that doesn’t work, either. I tried using a clean install of WordPress with no plugins and that failed, too.
An example of my CSS for the webfonts is:
@font-face { font-family: AntarcticanMono; src: url(web-fonts/AntarcticanMono-Bold.woff2); font-weight: bold; } h1 { font-family: 'AntarcticanMono'; font-weight: bold; }
Sorry for not having a link, but I’m developing this internally.
- The topic ‘Webfonts only load on home page.’ is closed to new replies.