Hi, I love the lazy load function, and I was wondering if there is a way to keep it from working on images above the fold as it seems to hang a bit before showing.
Hopefully, that makes sense. Basically just want to have the main images to show when our readers hit the page and then have the lazy load work as they scroll down. It seems to take an extra second to load images that are above the fold and readers just see grey boxes.
Thanks!
Hi,
The Lazy load will start to work only when you start to scroll down, clear all the caches, purge CDN files and check the results.
Cloudflare (CDN) -> https://forum.tagdiv.com/cloudflare-cdn/
Please make sure that you do not have a plugin conflict with untested plugins, please deactivate all non theme/tested plugins, also if you are using child theme cache plugin, clear all cache deactivate them and try again.
Also please you can check others settings from theme panel for lazy load -> https://www.screencast.com/t/0SXMx84QqSSU
Thank you!
It’s not about a plugin conflict.
What I actually stated in my original post was asking if there is a way to have the images on a site load above the fold and then lazy load works from there. Currently, with lazy load ticked, when our site comes up it’s just a grey screen for nearly 1.5 seconds. The reader has to begin to scroll down for those to show up.
As most people know, people don’t begin to scroll down until they see the full picture on an article or frontpage show up.
Hopefully you can understand what I’m saying. Basically, if the images above the fold of the sit can immediately pop up when opened, and then lazy load takes over from that point.
Hi,
I have checked this on our demo and you was right, for 1-2 second the thumbs are gray and only after that are load the image.
We’ll make some deep investigation for this problem, and we’ll try to find a solution for this as soon as possible.
For the moment you can deactivate our lazy load from theme panel and try some plugins.
Thank you for your understanding!
Hi,
I found the code needed to disable lazyload on an image class. I have searched through the theme editor, but I can’t find any lazyload code.
I’m hoping you can give me the correct newspaper code to add in place of the ‘rocket’ wording. I’ll then be able to also add the code for the front big grid section of the homepage. I think many Newspaper users will find this helpful, especially on mobile devices.
+++function rocket_lazyload_exclude_class( $attributes ) {
$attributes[] = ‘class=”td-post-featured-image”‘;
return $attributes;
}
add_filter( ‘rocket_lazyload_excluded_attributes’, ‘rocket_lazyload_exclude_class’ );+++
Hi,
Please make sure that you rocket loader is disable like in our guide ->https://tagdiv.com/how-to-set-up-cloudflare-cdn/
Your theme do not have such a function, I think that function comes from rocket plugin or CDN , please check the lazy load from those.
Also you have some errors in console that can provide some problems -> https://www.screencast.com/t/idq7LHsYb0Z
Thank you for your understanding!
This code is from WP Rocket.
What I was doing was showing you the code that will keep lazyload from loading Feature Images to find out how to make it work with the Newspaper Theme.
I’m sorry that my writing is not that good to understand. I am trying to be as specific as possible for you to understand.
The code I sent was code that works universally (in this case it was for WP Rocket) to keep Lazy Load from lazyloading feature images so they come up immediately and then lazyload does its thing for the rest of the page.
I am trying to find out where the code is in Newspaper for the lazyload function so I can apply (and rewrite the code specifically for the Newspaper them) it.
Hi,
Unfortunately, the WP Rocket plugin has not been tested with our theme and therefore, we cannot say for sure if it will work or not as expected with the theme, sorry! Also, we cannot provide support for untested plugins.
This is our list with tested plugins with our theme -> https://www.screencast.com/t/cmPkh9jba4sZ
All java-script that our theme is using is in wp-content/themes/Newspaper/js/tagdiv_theme.min.js if you want to change the java-script you need to make the changes in wp-content/themes/Newspaper/js/tagdiv_theme.js and use a minify js and replace the js in theme file.
Thank you for your understanding!