Tagged: x
-
AuthorPosts
-
April 26, 2016 at 2:36 pm #900866
rekluseParticipantHello,
For some reason my Post Carousel and Post Slider are not randomizing, even though both are set to “Random” in the customizer. But every time I refresh the page, the exact same pieces are being displayed in both the carousel and the slider, and in the exact same sequence.
Here is a link so you can see for yourself:
http://everyoneisright.com/media/
No matter how many times you refresh the page, you will see the same posts populating the carousel and slider every time.
Any idea what might have gone wrong? This definitely worked in the past.
Happy to provide login information if that helps.
Thanks!
April 26, 2016 at 8:14 pm #901277
rekluseParticipantFound some more strange behavior that seems to be related to this, just in case it helps figure out where the problem might be.
I am currently playing with trying to get Infinite Scroll plugin to work on our archive pages, following the instructions described here:
https://community.theme.co/forums/topic/infinite-scroll/page/3/
So I have it kinda-sorta working on this page:
http://everyoneisright.com/category/all-media/
But I notice that when the second page of media items loads, it leads with the exact same pieces that are being repeated in the Carousel and the Slider, and in the exact same order.
I also notice when I scroll further down the page that there are a bunch of badly formatted and overlapping items. Looking more closely at them, it turns out they are the same pieces in the same order, once again.
Not sure if this helps, or if maybe the slider data is actually being reproduced when the next page of assets loads, but I figured I would let you know.
(And if you have any advice to fix that Infinite Scroll overlapping issue, I would appreciate it — though I know that is a 3rd party plugin that may be beyond the scope of your support. But any good leads would be awesome!)
Thank you!
April 26, 2016 at 8:43 pm #901294
rekluseParticipantOkay, I just determined that the repeated items in the “Infinite Scroll” list is in fact coming from the Carousel and the Slider. Basically, every time Infinite Scroll tries to populate a new page, it repeats the items in the Carousel and Slider.
It’s unrelated to the main problem, but is there an easy way to exclude the carousel and slider data when using Infinite Scroll, so the media pieces all appear chronologically as it is supposed to?
http://everyoneisright.com/category/all-media/
I still cannot figure out why the carousel and slider are not randomizing though. None of them have ever been marked as “Featured”, I double checked that they were all set to “random” in the Customizer, and I even unpublished and republished some pieces, hoping that would somehow get the carousel and sliders working right. No luck =\
April 27, 2016 at 1:27 am #901514
rekluseParticipantI fixed the randomization issue.
We migrated to WP Engine yesterday, and I didn’t realize there was an “Allow ORDER BY RAND()” toggle in the WP Engine advanced settings, and it’s set to “disabled” by default. I’ll have to keep an eye on the possible performance hit by enabling it, as I will soon be migrating several hundred content pieces to the site. I’m sure it will be fine for the category subpages, but now I understand it can cause some serious slowdown if I set the post carousel and even the main blog page to random, as it will need to do a full database scan every time a page with a carousel or a slider is loaded.
A cool feature would be to be able to set the carousels and slider to do a random pull once an hour, and then show those results to everyone. Obviously that is beyond the scope of what you can offer here =)
If you have any general advice about this, I would love to hear it! And if you have any help to offer with the Infinite Scroll problem I described above (preventing the slider and carousel items from appearing in the list after the second page is loaded) that would be awesome too. Thanks!
April 27, 2016 at 6:13 am #901912
RadModeratorHi there,
That could be possible but I haven’t tried it yet. How about use WP transient to save carousel’s Query result for an hour. Then check the transient again if expired and re-query it again. That should enhance its performance.
Thanks!
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-900866 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
