Saltar navegación

[Resuelto] "Load More" pagination style

This support ticket is created 3 years, 3 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Zona horaria del colaborador: Asia/Hong_Kong (GMT+08:00)

Este tema contiene 1 respuesta, tiene 2 mensajes.

Última actualización por Luo Yang 3 years, 3 months ago.

Asistido por: Luo Yang.

Autor
Mensajes
#2555219

Hey guys,

I'm trying to do a simple "Load More" pagination option using the infinite scroll but it doesn't seem to work properly. This seems like a pretty normal bit of functionality when loading a list of posts.

Something like the example on this page is exactly what I'm looking for: enlace oculto

Not to load an entire new page of posts but to load more. Is that possible?

If this isn't possible can I link back to the top of the list after a user goes to the next page instead of just loading the new page at the bottom of the results (seems like it should do this by default).

I'm using the block view builder.

#2555473

Hello,

There isn't built-in "Load more" button feature within Toolset Blocks plugin, it needs custom codes, see below test site:
enlace oculto

Login URL: enlace oculto

1) Create a post view, in section "Pagination and Sliders Settings", enable option "Pagination enabled with manual transition and AJAX"-> Infinite scrolling

2) in section "Search and Pagination", add below JS codes:

(function ($) {
    $(document).ready(function () {
        $('.js-wpv-layout-infinite-scrolling').removeClass('js-wpv-layout-infinite-scrolling');
    });
})(jQuery);

3) in section "Loop Editor", just above shortcode [/wpv-items-found], add next page shortcode:
[wpv-pager-next-page]Load More ... [/wpv-pager-next-page]

Test it in frontend:
enlace oculto

It works fine.