logo-responsive
Welcome, Guest
Username: Password: Remember me

TOPIC: How to stop loading Google fonts from Google Servers in your template.

How to stop loading Google fonts from Google Servers in your template. 1 year 8 months ago #14520

  • JohnO
  • JohnO's Avatar
  • Offline
  • Administrator
  • Posts: 5377
  • Thank you received: 872
  • Karma: 98
How to stop loading google fonts from googles servers in your template.

STEP 1

OPEN THE FOLLOWING FILE - PHP/STYLES.PHP

A: Do a find for and remove
// remove websafe
$googlefonts = array_diff($googlefonts, $websafefonts);
// remove duplicates
$googlefonts = array_keys(array_flip($googlefonts));
// loop
foreach ($googlefonts as $v) {
    echo '<link rel="stylesheet" type="text/css" href="http://fonts.googleapis.com/css?family='.$v.':300,400" /> ';
}


B: Do a find for any instance of this text.
fonts.googleapis.com
If you find it then remove the complete line of code its in. Example
<link href='fonts.googleapis.com/css?family=Lato:400,300,100,700,900' rel='stylesheet' type='text/css'>


STEP 2


To remove them from being listed in the styling parameters do the following.
OPEN THE FOLLOWING FILE - ELEMENTS/GOOGLEFONTS.PHP

Do a find for
$googleFonts['Arial'] = '----------Google Fonts----------';

and remove it along with all the fonts listed below it in the array.
When you have this completed you will need to go into the template styling parameters >> Global Template Styling and select the websafe fonts you wish to use from the list and save.

You may also be interested in reading the following Tutorial - How to download and add a google font locally in my Joomla website >>

Thanks,
JohnO
Last Edit: 1 year 8 months ago by JohnO.
The topic has been locked.
Time to create page: 0.093 seconds
Powered by Kunena Forum

Newsletter




We respect your privacy and do not tolerate spam and will never sell, rent, lease or give away your information (name, email, number, etc.) to any third party. Nor will we send you unsolicited email.

Use code   FEB20 at checkout

    FEBRUARY    

10% off Everything!

Cookies make it easier for us to provide you with our services. With the usage of our services you permit us to use cookies.
Ok