-
AuthorPosts
-
January 11, 2019 at 6:17 pm #1052831
I am using a masonry for posts on a bar page. On the initial page load, the “excerpt” underneath the image does not load. If you to to filter” beach bar” or “bar” and then go back to “all” you they do seem to appear.
The issue appears when you choose “lazy loading” on jetpack. Is there a way to get it to work with this as we have had very good results with lazy loading on the mobile site.
Keith
- This topic was modified 5 years, 10 months ago by roamingk.
January 14, 2019 at 3:29 am #1053493Hey roamingk,
Thank you for using Enfold.
This script will force the portfolio grid to re-render or re-position until it’s fully loaded.
add_action('wp_footer', 'ava_auto_resize'); function ava_auto_resize(){ ?> <script> (function($){ var int = window.setInterval(function(){ console.log('tick'); $(window).trigger('resize'); $(window).trigger('av-content-el-height-changed'); }, 1000); $(window).on('load', function() { clearInterval(int); }); })(jQuery); </script> <?php }
Best regards,
IsmaelJanuary 14, 2019 at 5:13 pm #1053732Hi Ismael,
Do I add this to the functions script ? I added it here, but the issue is still occurring… I also cleared all caches.Keith
- This reply was modified 5 years, 10 months ago by roamingk.
January 15, 2019 at 12:33 am #1053889Hi,
You have to add it in the functions.php file. Please disable the cache and minification plugin temporarily.
Best regards,
IsmaelJanuary 15, 2019 at 6:31 pm #1054245Added the code to the end of the functions.php page, I cleared the cache, turned off the performance for enfold, purged all the cached pages and turned off the WP Jetpack hosting for images, but kept lazy loading on, and it still gives issue with the loading of the images, and sometimes the results are different with some images showing the excerpt below in the masonry and sometimes not.
Any ideas what I might be doing wrong?
KJanuary 18, 2019 at 11:46 am #1055404Hi,
Did you set jQuery to load in the footer? It’s an option in the Performance panel. The console reported that jQuery is not defined, so the script above is actually not being executed properly.
Best regards,
IsmaelJanuary 19, 2019 at 7:11 pm #1055953Yes, should I unclick it?
January 20, 2019 at 11:17 am #1056124Hi Keith,
Yes, please try to uncheck that option to see if it helps or not.
Best regards,
RikardJanuary 21, 2019 at 2:00 pm #1056643Hello, I disabled that option and cleared the cache. The issue is still occurring. Results are inconsistent on each refresh.
January 21, 2019 at 4:49 pm #1056782Hi roamingk,
Well, masonry and images lazy load are not really compatible at this point.
Best regards,
VictoriaJanuary 21, 2019 at 5:18 pm #1056810ok I will disable and wait until you have an update :-) thanks for the assist so far.
January 21, 2019 at 6:27 pm #1056841I do not have lazy loading enabled and am still seeing this behavior on Masonry after the last update, even with animation turned off.
It seems like you have to scroll past the masonry and to get it to “fire”…January 22, 2019 at 1:06 pm #1057174Hi Rob,
I could not reach your website today. Are blocking locations?
Best regards,
VictoriaJanuary 22, 2019 at 5:02 pm #1057309Hi Victoria and happy 2019!
Yes I was blocking locations to reduce bots… blocking is turned off except for China now. Let me know please if you need China opened as well.Best,
RobJanuary 23, 2019 at 4:40 pm #1057797Hi Rob,
No, we don’t need China. The images load with animation on my end.
Best regards,
Victoria -
AuthorPosts
- You must be logged in to reply to this topic.