Query Loop Load More
This WordPress plugin adds a load more option to the Query Loop Pagination block in Gutenberg, allowing users to load more posts without refreshing th …
Install in
This WordPress plugin adds a load more option to the Query Loop Pagination block in Gutenberg, allowing users to load more posts without refreshing the page. It replaces the traditional Previous Next and numbered pagination, with a customizable, Load More button.
Instructions
To use this plugin, you must first add the Query Loop block into your post content, then add the Pagination block inside the Query Loop. When working with the Pagination block, you will see new options to enable load more on the block.
The load more option allows you to set a loading text parameter and also the button text. The load more button works with the alignment options and arrow options of the pagination block.
Here is how to enable the load more option:
- Add the Query Loop block to your post content.
- Inside the Query Loop block, add the Pagination block.
- In the Pagination block settings, enable the “Load More” option.
- Set the loading text parameter and the button text.
- Customize the alignment and arrow options if desired.
That’s it! Your visitors can now load more posts by clicking the load more button without refreshing the page.
Customization Options
- Alignment: Use standard block editor settings to set the alignment of the load more button
- Button: Choose the button option for users to click to load more posts
- Button Text: Customize the load more button text
- Loading Text: Customize the text for the post loading state
- Infinite Scroll: Choose this option to allow new posts to load automatically when users reach the bottom of the feed
- Color and Typography: The Pagination block’s Color and Typography settings style the load more button and the no more posts text. The infinite scroll loading animation has its own color setting
- Arrow: The Pagination block’s Arrow setting adds an arrow after the button text. Turn off Show label text for a button with only the arrow; screen readers still get the text
- No More Posts Text: Set a text to show at the end of the list once every post has loaded
- Update URL: Choose this option to update the browser’s URL when loading more posts
Written by Joobi from the project's own listing. See the source page
1.0.21
- Security – Infinite scroll now stops when the page it loaded has no next page, so a hand-coded Load More button cannot keep requesting pages
- Security – A Load More response that was redirected to another site is no longer used
- Fix – A PHP warning and an empty arrow element when the Pagination block’s arrow is set to a value the plugin doesn’t know
1.0.20
- Security – The Load More button now only requests the plugin’s own numbered pagination parameter and only accepts an HTML response, so a post author cannot point it at another endpoint and get markup from that response to run in a visitor’s browser.
- Add – The Pagination block’s Color and Typography settings now style the Load More button and the no more posts text
- Add – With an arrow set, turning off Show label text shows only the arrow on the Load More button
- Fix – A square box showing around the infinite scroll loading animation
- Update – License changed to GPLv2 or later
1.0.19
- Add – Optional text to show once every post has loaded
- Fix – Infinite scroll not loading more posts when nothing follows the Query Loop on the page
- Fix – Infinite scroll stopping when a loaded batch of posts was short
- Fix – A failed request for more posts being retried in a tight loop
1.0.18
- Fix – Updated composer.json PHP requirement from 8.3 to 8.0 to match plugin requirements
1.0.17
- Fix – potential issue infinite scroll not triggering if button is at the bottom of the viewport
- Fix – Page parameter for inherited queries
- Fix – Page parameter for custom query page when not set
- Fix – Keep current URL parameters when fetching new posts and updating the location URL
- Update – Changed event listener of manual load more buttons to be attached to the document instead of each individual button
1.0.16
- Fix – Makes query loops QueryID agnostic and fixes multiple loops in a page where one exhausts before the other.
1.0.15
- Optimisation – Assets only load on pages using a pagination block.
- Fix – Query loops now correctly use QueryID, allows supporting multiple queries on the page.
1.0.14
- Fix – Fixed posts not loading on infinite scroll if site has no footer.
1.0.13
- Fix – Fixed link without text when inifnite scroll is enabled.
1.0.12
- Fix – Fixed the query pages comparison check.
1.0.11
- Fix – Fixed warning about _load_textdomain_just_in_time.
- ADDED – Javascript event document.qllmLoadStart when load more button is clicked.
- ADDED – Javascript event document.qllmLoadEnd when loading is completed.
- FIX – The load more button now respects the max number of pages on a query if a limit was manually set.
1.0.10
- Fix – Fixes load more button wrapping.
1.0.9
- Fix – Loading more posts for query blocks with no or zero as the queryId
- Fix – Keeping original button content after loading more posts. Fixes pagination arrow
1.0.8
- Fix – Only use intersection observer if infinite loading setting is active
- Fix – Use global query to get maximum amount of pages if query is set to inherit
1.0.7
- Fix – Loading posts ( multiple query blocks, loading posts from correct query block )
- Fix – URL related issues ( new setting for updating the URL, update paging parameter without changing base URL )
- Update – Using only one button, including infinite scroll
- Update – Changed default behavior – not updating the URL by default – added a setting to re-enable
- Update – Build scripts
1.0.6
- Update – Add loading class when in loading state
1.0.5
- Fix – Infinite scroll would duplicate some posts due to the same AJAX call being executed twice
1.0.4
- Update – Version
1.0.3
- Fix – Loading more posts on “Inherit query from template”
1.0.2
- Add – SVN deployment workflow
- Update – Version and Stable tag
1.0.1
- Fix – Unify GPL license
- Fix – Unify text domain and plugin slug
1.0.0
Initial release.
Follow this listing's changes (Atom feed)