-
mkuhnell
I’m trying to re-create my old category page with Blocks. Previously the posts were displayed with Justified Image Grid in order to do the Load More pagination and the filter by tag. Can I do this in Generateblocks now? Or do I still need JIG? Or would you recommend another option? Thanks!
-
Alvind
Hi there,
Currently, the filtering feature is not available in the current version of GenerateBlocks. The Load More button is an option only for theme archive and blog pages, it won’t work with the GenerateBlocks Query Loop block on a static page. Load More for those blocks is a planned future feature.
-
mkuhnell
I am referring to the theme archive page, so how do I implement Load More there?
I’m sad to hear that you aren’t using AJAX filters for Generateblocks and hope that you might add them in the future. Is it possible to use Category Ajax Filter or a similar plugin to filter the archive page and then customize the layout in GeneratePress/Blocks?
-
David
Hi there,
you can’t use a GP Block Element – Loop Template , if you want Load More. That will come in the future.
What you can do is design the post template for the archive pages using Block Element – Content Template:
https://docs.generatepress.com/article/block-element-content-template/
That will still use the Themes loop so it can use the Load More option in the Customiser > Layout > Blog
If you want to add content before or after the loop, then you can use other Block elements like a Page Hero to add that content.
-
mkuhnell
OK, thanks! How do I specify that block elements (other than the Page Hero) go before or after the loop?
-
David
If you leave the block element type as a Hook, you can choose from a list of Hooks.
See here for reference on their positioning:https://docs.generatepress.com/article/hooks-visual-guide/#archives
-
mkuhnell
Ok, thanks!
And about the filtering — Is it possible to use Category Ajax Filter or a similar plugin to filter the archive page and then customize the layout in GeneratePress/Blocks?
-
I believe Filter Everything should work but you may need the paid version to work with GB’s query loop block.
You can certainly test the Category Ajax Filter as well 🙂
-
mkuhnell
Thanks!
-
No problem 🙂
-
Patrick
Hi Support,
Is there any chance I can use your code hooks & gp scripts to build the button myself via custom code for Loop Template or Query Loop Block?
As far as I can see, you use https://infinite-scroll.com/ and a custom script.Appreciate your help 🙂
Thanks,
Patrick -
Hi Patrick,
It will require custom development which is out of the scope of the support forum.
-
Patrick
Hi Ying,
Thanks for your fast reply.
I do understand that you can’t provide support for custom development,
but could you please assist with hooks/scripts I can use that are part of GP/GB?That would help me a lot to get started.
Thanks,
Patrick -
I’m not sure what you mean by hooks, the hooks are in the visual hook guide: https://docs.generatepress.com/article/hooks-visual-guide/
And what exact script are you looking for?
-
Patrick
Hi Ying,
I mean WP Hooks (actions & filters), Plugin/Theme devs provide to hook into.
I would like to know which code and scripts you use to provide the Load More/Infinite Scroll functionality in your Blog Settings. There must be some type of AJAX call or so to load more posts on scroll/btn click.
I am asking for help deciding which GP code I can use without building the whole thing myself or debugging your code to gain some insights. Sometimes, your devs can share some code snippets or insights on how this could be achieved.
Hope that helps with what I am looking for 🙂
Thanks
-
Hi there,
GP uses this infinite scroll package:
the MetaFizzy documentation is quite good and should help with any custom developments.
- You must be logged in to reply to this topic.