-
Davepp
Hi There,
I’ve been through the forum and have seen a few posts that detail the same issue, that fonts uploaded to the font library break when pushed between live and staging. I’ve been using disabling/re enabling the font to get the fonts back, but the site in question would be pushed live a few times a day by the client. Is there any alternative until a fix is in place? Can I exclude anything from the deployment? Add the font in a different way?
Thanks
Dave
-
Alvind
Hi Dave,
When you mentioned that it would be pushed live a few times a day, do you mean a full site push or just incremental changes?
If it’s only incremental, the font library shouldn’t have any issues. Once you disable and re-enable the font after the first migration from staging to live, the font stylesheet will have already regenerated and be referencing the live URL.
This is something we’re actively looking to improve.
-
Davepp
Hi Alvind,
Unfortunately, this isn’t the case for this setup. The site is being fully deployed from staging to live & the fonts having to be re-enabled each time. Is there a workaround/alternative I can use?
Thanks
Dave
-
The site is being fully deployed from staging to live & the fonts having to be re-enabled each time.
A workaround would be to access the
fonts.cssfile atwp-content/uploads/generatepress/fonts/fonts.css, and change the absolute URL to relative URL.For example, if the font file URL in the fonts.css is
https://your-domain.com/wp-content/uploads/generatepress/fonts/inter/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hiA.woff2Change it to
/wp-content/uploads/generatepress/fonts/inter/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hiA.woff2As long as you don’t touch the font library, the font file URL should be using relative URL, and it should not be affected by the migration.
-
Davepp
Thanks Ying,
I’ll give that a go. Would this be overwritten by theme updates?
Thanks
Dave
-
I don’t think so, but let me know if it does 🙂
- You must be logged in to reply to this topic.