Skip Navigation

[Resolved] Cannot get Google fonts to work with Toolset and my bootstrap starter theme

This thread is resolved. Here is a description of the problem and solution.

Problem:

I cannot get google web based fonts to load in my website.

Solution:

I suggest you try to follow WordPress document to register and enqueue the your custom CSS files:

https://toolset.com/forums/topic/cannot-get-google-fonts-to-work-with-toolset-and-my-bootstrap-starter-theme/#post-1209198

Relevant Documentation:

https://developer.wordpress.org/reference/functions/wp_enqueue_style/

This support ticket is created 3 years, 4 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

This topic contains 2 replies, has 2 voices.

Last updated by Robert Campbell 3 years, 4 months ago.

Assigned support staff: Luo Yang.

Author
Posts
#1208945

I am using Toolset with a new Bootstrap starter theme which you kindly gave me assistance to get working.

You can see my test site at hidden link

Problem: I cannot get google web based fonts to load.

As an example, I have added the following in my header
<link href="hidden link" rel="stylesheet">

And to my child theme CSS
body{
font-family: 'Srisakdi', cursive;
}

If you look at the home page using Google inspector, you can see that the font has been computed properly but is not actually rendered.

Could you have a look please and see if you can spot the problem.

Regards

Robert

#1209198

Luo Yang
Supporter

Languages: English (English ) Chinese (Simplified) (简体中文 )

Timezone: Asia/Hong_Kong (GMT+08:00)

fonts.JPG

Dear Robert,

This is a custom CSS code problem, I have tried the URL you mentioned above, here are what I found in your website:
I don't see the CSS file was loaded in my browser, see screenshot: fonts.JPG

I suggest you try to follow WordPress document to register and enqueue the your custom CSS files:
https://developer.wordpress.org/reference/functions/wp_enqueue_style/

For example, this post from other website:
hidden link

And test again

#1209678

My issue is resolved now. Thank you!