infinite scroll button

  • Posts: 507
  • Thank you received: 21
  • Hikashop Business
1 year 4 months ago #352571

-- HikaShop version -- : 4.7.3
-- Joomla version -- : 4.3.2
-- PHP version -- : 8.1

Hi,

Would it be possible to activate the infinite scroll with a button, so the customer can decide when to load more products instead of the page keeps loading until all products are loaded? On pages with a lot of products this can be somewhat annoying.

The following user(s) said Thank You: ssnobben

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
1 year 4 months ago #352574

Hi,

If you want to have the infinite scroll and have it triggered only when the user manually click on the "load more" button can be done with a small view override. For that, go in the Display>Views and edit the product / listing_div view file and remove that code:

window.Oby.addEvent(window, 'scroll', function() {
	window.localPage.checkInfiniteScroll('<?php echo $mainDivName; ?>');
});
window.Oby.addEvent(window, 'resize', function() {
	window.localPage.checkInfiniteScroll('<?php echo $mainDivName; ?>');
});

The following user(s) said Thank You: ssnobben

Please Log in or Create an account to join the conversation.

  • Posts: 507
  • Thank you received: 21
  • Hikashop Business
1 year 4 months ago #352640

O, great, thanks!

The following user(s) said Thank You: ssnobben

Please Log in or Create an account to join the conversation.

  • Posts: 67
  • Thank you received: 4
1 year 3 months ago #353825

implement in next version?

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
1 year 3 months ago #353832

Hi,

No. However, you can do it as a view override quite easily as I wrote in my previous message here.

The following user(s) said Thank You: ssnobben

Please Log in or Create an account to join the conversation.

  • Posts: 67
  • Thank you received: 4
1 year 3 months ago #353933

nicolas wrote: Hi,

No. However, you can do it as a view override quite easily as I wrote in my previous message here.


Ok we have to live with that solution then..

cheers!

Please Log in or Create an account to join the conversation.

Time to create page: 0.069 seconds
Powered by Kunena Forum