How to load Google Font from local server
Posted: 30 Aug 2022, 14:30
Hi,
I am using the Gweld template. A Google Font is used in this template.
For data protection reasons, I no longer want to integrate Google Fonts from the Google server.
I am still using Joomla 3.10.11
I tried the following steps:
I looked for the Font Open Sans on https://google-webfonts-helper.herokuapp.com/
I downloaded the font files from here: https://google-webfonts-helper.herokuap ... sets=latin
and extracted the files in templates/phoca_gweld/fonts.
Then I copied the necessary CSS code into templates/phoca_gweld/css/custom.css.. The CSS file custom.css is loaded by the Joomla plugin Add Custom CSS.
In templates/phoca_gweld/index.php I see the line of code, where the Google Font is loaded from the Google server. I suppose, this line has to be changed or deleted.
<link href='https://fonts.googleapis.com/css?family=<?php echo $nameGFont1; ?>&subset=latin,latin-ext' rel='stylesheet' type='text/css'>
Deleting this line lets the site fall back to a not very beautiful font. The local saved Google Font obviously does not get loaded.
I am very grateful for every hint.
I am using the Gweld template. A Google Font is used in this template.
For data protection reasons, I no longer want to integrate Google Fonts from the Google server.
I am still using Joomla 3.10.11
I tried the following steps:
I looked for the Font Open Sans on https://google-webfonts-helper.herokuapp.com/
I downloaded the font files from here: https://google-webfonts-helper.herokuap ... sets=latin
and extracted the files in templates/phoca_gweld/fonts.
Then I copied the necessary CSS code into templates/phoca_gweld/css/custom.css.. The CSS file custom.css is loaded by the Joomla plugin Add Custom CSS.
In templates/phoca_gweld/index.php I see the line of code, where the Google Font is loaded from the Google server. I suppose, this line has to be changed or deleted.
<link href='https://fonts.googleapis.com/css?family=<?php echo $nameGFont1; ?>&subset=latin,latin-ext' rel='stylesheet' type='text/css'>
Deleting this line lets the site fall back to a not very beautiful font. The local saved Google Font obviously does not get loaded.
I am very grateful for every hint.