Support views pager query string variables (i.e. view-path?page=1)

Created on 4 July 2016, over 8 years ago
Updated 15 July 2024, 5 months ago

Currently if you have pager query string variables in your url (e.g. path/to/my/view?page=2), you only get the items for that page. It should probably show you all items up until the specified page to match what the user would have been seeing when they got there using the page.

For example, when used in conjunction with Views AJAX History , each load more click increases the page number in the url by one, and visually you see all items from 0 to current_page * items_per_page. However, the way it works currently, when you navigate back to this page (using the browser back button for example) you only see the items for that page number.

Attached patch adds a query() method to the load more views plugin that remedies the issue.

I believe this patch will also fix a similar issue users are seeing in #1411380: Support for HTML5 history API (browser back button) .

🐛 Bug report
Status

Needs review

Version

1.0

Component

Code

Created by

🇨🇦Canada drclaw

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024