- Philippe Hong(Private) July 12, 2019 at 1:06 pm #216170
I have an issue with the pagination, when going to the next pages, it will always show the first page results…
It will work when searching for a term but not when filtering with a category or anything. You can try this on uigarage.net.
thanks a lotTrevor Moderator(Private) July 12, 2019 at 2:58 pm #216205
This looks like it is something to do with the search.php template file. The pagination is not actually made within that file, but by a function in a called template (/pages/gallery.php):
I cannot find that function though. Do you know which theme file that function is defined in?Trevor Moderator(Private) July 12, 2019 at 5:36 pm #216230
Try something like this:
<div class="pagination"> <div class="nav-previous"><?php next_posts_link( 'Older posts', $query->max_num_pages ); ?></div> <div class="nav-next"><?php previous_posts_link( 'Newer posts' ); ?></div> </div>
$query might have to change depending on what your query array is named. It is basic but is a place to start.
Please note that we are closed for the weekend and any replies may be delayed until we open at 10AM (UK time) on Monday.
You might also want to test things out by making a really basic search using the shortcode method to see if it works then:
The topic ‘Search pagination always return the first page’ is closed to new replies.
Our support hours are:10am - 5pm (GMT), Monday - Friday
Please be aware that tickets opened over the weekend will looked at on Monday.