- This topic has 11 replies, 3 voices, and was last updated 4 years, 7 months ago by Tom.
-
AuthorPosts
-
September 24, 2019 at 1:46 pm #1018052Olaf
Hi.
I’ve changed the fonts via Customizer to browser fonts. body = Tahoma, everything else inherit.
But still the google fonts are loaded … even if I add the following code to the functions.php:
add_action( ‘wp_enqueue_scripts’,’tu_remove_google_fonts’, 10 );
function tu_remove_google_fonts() {
wp_dequeue_style( ‘generate-fonts’ );
}What can I do to stop it? Many thanks in advance.
September 24, 2019 at 2:03 pm #1018069DavidStaffCustomer SupportHi there,
just checked your site and i cannot see any google font requests. Maybe its cached in your browser?
September 25, 2019 at 12:04 am #1018323OlafHi David
thanks for the quick answer.
When I check the website with https://tools.pingdom.com it says that Google sends a request (fonts.googleapis.com). The same result in Developer Tools (Chrome).
I’ve deleted my browser cache, checked all plugins and integrated the following code:
add_action( ‘admin_init’, ‘tu_remove_google_fonts’ );
function tu_remove_google_fonts() {
add_filter( ‘generate_google_fonts_array’, ‘__return_false’ );
}Maybe you have another idea where the request is hiding!? π
September 25, 2019 at 2:58 am #1018419DavidStaffCustomer SupportGT Metrix for me has no Google fonts. Pingdom does which may mean its getting a CDN Cacheed file.
Does your server use CloudFlare ? If so give that a clean.September 26, 2019 at 7:23 am #1019596OlafHi David
GT Metrix finds the request, too. π
Could you please have a look at the tab “Waterfall”?
You’ll find “fonts.googleapis.com” at the lower part. The font is “Montserrat”.
I don’t use CloudFlare.
—–
And I have a new problem: When you load the website for the first time, you can only see the bottom half of the logo. After you reload the page, the logo is in its desired position (mobile & Desktop, Chrome) … but that seemingly doesn’t work in FF. Strange, isn’t it?
I use Autoptimize and have cleared the cache.
September 26, 2019 at 7:54 am #1019745DavidStaffCustomer SupportLooks like the Pop Up maker is calling the google font.
You have some CSS that is moving the logo position up ?September 26, 2019 at 9:18 am #1019815OlafHi.
And thanks again for the fast answer.
Problem 1 solved!!! It was the Pop Up Maker … Thanks for the indication.
—
“You have some CSS that is moving the logo position up ?”
If we have than it was not on purpose. π
September 26, 2019 at 9:52 am #1019854DavidStaffCustomer SupportCheck in the Customizer > Additional CSS – remove this:
.site-branding, .site-logo { position: absolute; left: 50%; -webkit-transform: translateX(-50%); transform: translateX(-50%); z-index: 200; }
September 26, 2019 at 12:50 pm #1019976OlafHi David
that works. Thanks again.
But now another – maybe my last – question: π
How can I now center the logo again?
September 26, 2019 at 4:33 pm #1020075TomLead DeveloperLead DeveloperHi there,
Try this CSS:
.site-logo { margin-left: auto; margin-right: auto; }
Let me know π
September 26, 2019 at 9:32 pm #1020141OlafYeah. Works. Thanks a lot! π
September 27, 2019 at 8:58 am #1020586TomLead DeveloperLead DeveloperYou’re welcome π
-
AuthorPosts
- You must be logged in to reply to this topic.