-
AuthorPosts
-
May 17, 2018 at 2:19 pm #958167
Hello support team,
I have observed that the masonry element wich I use for my blog only displays if the page is scrolled. I suppose that this has changed with one of the last theme-updates. In my memory the masonry in the past did display correct on loading the page. Is this a bug?Best regards,
lebenspraxisMay 19, 2018 at 9:20 am #958975Hey lebenspraxis,
I can’t reproduce that on my end using Chrome, in which browser are you seeing that? Also, are you sure that you are not getting cached results?
Best regards,
RikardMay 19, 2018 at 3:45 pm #959095Hey Rikard,
it’s only appearing on desktop. And yes, I’m sure that this aren’t cached results. I get the same result with Firefox 59.0.3 and MS Edge 41.16299.371.0, both on Windows 10. Masonry is only displaying when scrolling.
Best regards.
lebenspraxisMay 19, 2018 at 6:46 pm #959131Hi,
I believe you are referring to the masonry animation, please try this code in the General Styling > Quick CSS field to remove:.avia_desktop.avia_transform3d .av-masonry-entry.av-masonry-item-loaded .av-inner-masonry{ -webkit-animation: none !important; -moz-animation: none !important; animation: none !important; } .av-masonry-entry { opacity: 1 !important; visibility: visible !important; }
Best regards,
MikeMay 20, 2018 at 11:07 am #959402Hey Mike,
maybe we could say it‘s about masonry animation, yes. But the animation is really nice and I want to maintain it. The problem is that the animation should start while the page is loaded and not only when the user scrolls the page. If one doesn‘t scroll the page, the masonry and it‘s content do not display. That behaviour will increase the bounce rate and makes no sense for me.
I didn‘t try your code, because it‘s not what I want.
Best regards,
lebenspraxis
May 20, 2018 at 7:28 pm #959485Hi,
Try adding this code to the end of your functions.php file in Appearance > Editor:function scroll_on_load(){ ?> <script> jQuery(document).ready(function($) { $('html, body.page-id-480').animate({ scrollTop: (5) }, 'slow'); }); </script> <?php } add_action('wp_footer', 'scroll_on_load');
It has be written to only work on your blog page.
Best regards,
MikeMay 20, 2018 at 9:58 pm #959511Hi Mike,
thank you very much for writing a code for my blog page! But I’m sorry, the code didn’t work. I put the code into the functions.php of my child-theme without any changes in the behaviour of the blog page. I thougt it should work with the functions.php of the child theme or is that wrong?Best regards,
lebenspraxisMay 20, 2018 at 10:51 pm #959521Hi,
I checked and it is working for me, with Chrome.
Perhaps try clearing your browser cache.Best regards,
MikeMay 21, 2018 at 1:25 pm #959742Hi Mike,
the browser cache is not the problem. I always clear all the caches before testing: browser cache, autoptimize, cache enabler.
On desktop with Firefox and MS Edge it doesn’t work, sorry.Best regards,
lebenspraxisMay 22, 2018 at 6:11 am #960149Hi,
Strange, I tested with Chrome, Firefox, Edge & IE11 and found it working.
Try changing the line:
scrollTop: (5)
to:
scrollTop: (10)Just to make sure we are looking at the same thing I made a video in the Private Content area, watch for the masonry blog posts at the bottom of the page on page load. The video was made in Windows 10 Edge.
Best regards,
MikeMay 22, 2018 at 7:17 pm #960482Hi Mike,
thank you for making videos to see if we’re looking at the same thing! I see that it all works as it should in your test. Have a look at my videos (private content) and you will see that in my test the masonry only loads when I scroll. Before loading the page I clear the browser cache. Strange thing!
Changing that line in the code had no result. What’s happening here and how can I get it work?Best regards,
lebenspraxisMay 23, 2018 at 2:08 am #960582Hi,
Well it’s not working for me today, strange and now you have a new error.
seems something has changed with your site, were you using this caching plugin when we started working on this? Have you added anything new?
I wanted to see the code in your functions.php, but your editor is disabled, can you enable it or do you add your code another way?Best regards,
MikeMay 23, 2018 at 12:28 pm #960762Hi Mike,
I got an error on my site some hours ago caused by the last update of the statify-plugin. Because I worked on some things including .htacces-file I first thought I made a mistake. Took me some time to find out what happened.I use Autoptimize for a long time and it is realy good, also cache-enabler. Working fine together.
The editor was disabled by the hosting provider from the beginning. In the beginning I had a managed wordpress installation. For that I just didn’t know that there normally is such an editor in wordpress. I edited the files via ftp and a desktop editor. I provided ftp-login-credentials for you in an earlier post. For the moment I enable the editor for you. For security reasons I will disable it when the issue is solved.
Best regards,
lebenspraxisMay 24, 2018 at 4:34 am #961322Hi,
Thank you for that. I found that our screens are a little different in sizes, so on my screen the masonry was up a little more to trigger the animation, while on your screen was not.
So I did two things to correct, first I added the code to a code block on the page to ensure it would trigger. Second I removed 20px of top margin from the special heading via WordPress > Customize > Additional CSS, to bring the masonry up just a little so it will work, or at least I think it will for you now.
Please check, Thank you.Best regards,
MikeMay 24, 2018 at 5:17 pm #961718Hi Mike,
great work! Thank you so much! Now it works fine. I will look into how you solved it later. At least it is how I wanted it to be.
You can close this thread now.Best regards,
lebenspraxisMay 25, 2018 at 1:43 am #961910Hi,
Glad we were able to help, we will close this now. Thank you for using Enfold.For your information, you can take a look at Enfold documentation here
And if there are features that you wish Enfold had, you can request them and vote the requested ones here
For any other questions or issues, feel free to start new threads under Enfold sub forum and we will gladly try to help you :)Best regards,
Mike -
AuthorPosts
- The topic ‘Masonry element only loads when scrolling the page – bug?’ is closed to new replies.