Advice/examples for creating a classified ad section for my site
Started by: johnG-13
in: Toolset Professional Support
Quick solution available
2
3
3 years, 3 months ago
johnG-13
Listing map items in order of distance
Started by: simonC-7
in: Toolset Professional Support
Quick solution available
2
4
3 years, 3 months ago
simonC-7
Create “load more” button with toolset blocks
Started by: Fred
in: Toolset Professional Support
Quick solution available
Problem:
How to create a Load More button in Toolset?
Solution:
Legacy Views:
- Create a view with "infinite scroll" feature:
https://toolset.com/documentation/user-guides/infinite-scrolling-in-views/
- In the "Loop Editor" section, insert the next page link shortcode between
[/wpv-items-found] and [wpv-no-items-found], for example:
[/wpv-items-found]
[wpv-pager-next-page force="true"][wpml-string context="wpv-views"]Load More Button here ...[/wpml-string][/wpv-pager-next-page]
[wpv-no-items-found]
- In the JS Editor add the code below:
(function ($) {
$(document).ready(function () {
$('.js-wpv-layout-infinite-scrolling').removeClass('js-wpv-layout-infinite-scrolling');
});
})(jQuery);
Views Block:
Add the same items above inside the pagination options in the sidebar of the Views options.
You still will need a shortcode block and add the shortcode mentioned above for the button itself.
Relevant Documentation:
https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-pager-next-page
2
9
3 years, 3 months ago
Fred