Archived topic
Mobile menu messed up
7 replies · Started by Brian on October 28, 2020
Hi I have an odd issue. The menu is perfect but often when I go back a page the mobile menu gets bigger. See screenshot.
Thanks
Hi there,
the problem is generally related to the Lazy Loader.
What plugin are you using to lazy load your images - they generally have an option to exclude images based on a CSS class - you can use this CSS Class: is-logo-image
Sorry for the delay, i forget to tick notify me.
I am using perfmatters. Their support says
https://perfmatters.io/docs/lazy-load-wordpress/
If you have access to add a CSS class to the specific image you are wanting to exclude, simply add the no-lazy class and it should be ignored when the document is being prepared for lazyloading.
Could you tell me how to apply this class to the logo in GP?
Thanks
On the page you've linked, there is a section "If you are using the GeneratePress theme, you can use this snippet of code:"
Have you tried that code?
Thanks Leo, but what do i do with the file they link to? There is no instructions on what to do with it. Save it to the theme folder?
You can add that code using one of these methods:
Adding PHP: https://docs.generatepress.com/article/adding-php/
Thanks Leo I added it to functions.
No problem :)