Questions tagged [pagination]

Breaking up content into smaller-sized pages to be viewed individually

Filter by
Sorted by
Tagged with
0
votes
0answers
9 views

add next and prev post arrows

I want to create a simple one page storytelling wordpress website. I've created a category to hold all the posts that will be the main content for the stories and I want to display them on the ...
0
votes
1answer
390 views

query posts returns 10 records

I am using the following code to fetch records from a custom taxonomy. if ($_GET['post_type'] == "developments"){ ?> <?php global $wp_query; ...
3
votes
2answers
2k views

List posts based on first letter of posts

I want add a pagination How can I do this on both loop.php and search.php. I want show alphabetic index to search only posts with starting letter = [E] for example. Right now, if I search with E it ...
1
vote
0answers
38 views
+100

Wordpress API returns empty page when page is less than X-WP-TotalPages

I am querying in the Wordpress API for all pages of media attachments. I am going page by page. I have about 5800 pages and when I hit pages 50-53 they return a blank or more of a [] but it is a ...
0
votes
1answer
479 views

Pagination not working on homepage

I tried multiple solutions but its not working. When I go to /page/2, it doesn't work. I'm executing custom query in index.php of my theme. if ( get_query_var('paged') ) { $paged = get_query_var('...
2
votes
1answer
540 views

Wordpress custom URLs for pagination pages

I’m trying to find a way to make custom URLs for each pagination page separated by <!--nextpage--> tag. For example, if the first page is: myblog.com/my-topic/ the second one will be: myblog....
1
vote
0answers
8 views

How to show all pages in blog navigation?

I'm trying to show all pages (ex. 6) in pagination navigation in my blog. I've got following code in my functions.php: function numeric_posts_nav() { if( is_singular() ) return; ...
1
vote
0answers
11 views

Pagination with no 'page' slug

I have pagination on my archieve page - it looks like mysite.com/category/product/page/2. How can I disable/remove 'page' slug? I want it to look like mysite.com/category/product/2. Thanks in ...
0
votes
1answer
443 views

Custom Select Query pagination not working properly

I have Custom Select Query joining two tables and displaying events older than current date. Everything works fine until I try to paginate it. <?php global $wpdb; $date = date("Y-m-d");...
0
votes
0answers
12 views

Pagination clones posts to next page

I have this archive page where I'm displaying some cards. I've run into a problem where cards would duplicate to next page. https://gyazo.com/1cd8689cba6d352f9c7fad28255b78ab The thing is that ...
-1
votes
4answers
3k views

How to add pagination for wordpress home page

Hi I am using thevoux theme for my website as i need to add pagination links like "Older Posts and Newer Posts" to home page.Here is an example screen shot how it should be. Actually right now i am ...
1
vote
1answer
571 views

Pagination in plugin's backend

I am displaying a list of posts in the plugin backend but I can't seem to get the pagination to work. I used the standard approach of getting the "paged" variable and then passing it to get_posts()'s ...
1
vote
1answer
437 views

Pagination - works on local but not live dev!

Can anyone please shed some light as to why the following to print out page numbers works on my local dev server but not on my live server? Both server are running same version of PHP. My Loop <?...
3
votes
1answer
586 views

Pre get posts for single post

I pre get posts for a events archive page: http://www.netzwerk-leipziger-freiheit.de/veranstaltungen/ function my_pre_get_posts( $query ) { // do not modify queries in the admin if( is_admin() ){...
0
votes
1answer
434 views

Pagination 404 Not Found child page

I have a page Heemtijdinghen displaying custom posts (post_type=artikel) paginated. The page is a child page of page Publicaties: /publicaties/heemtijdinghen/ When navigating to e.g. page 2 a 404 Not ...
2
votes
3answers
1k views

How to remove WordPress category from URL and have a custom pagination parameter/rewrite?

I'm trying to remove the Category URI from the WordPress URL and have a custom pagination rewrite. I'll explain exactly what's happening below: So I have a blog. We have two (main) categories: "bar-...
0
votes
1answer
487 views

offset and max_num_pages in pagination gallery

I rewrote the code galleries and stopped at the pagination. How can I get the maximum number of pages? at the moment I can not define it, and put a test for the number 5. (Here "for ($ i = 1; $ i &...
1
vote
0answers
20 views

Restoring default article pagination on archives – Removing custom limits

I am working on a website that is a customised WordPress installation running WP 5.2.4. There are a number of categories, as follows: main_category (id 71) other_cat_1 other_cat_2 etc. The post ...
0
votes
1answer
511 views

How to limit page pagination… again

I'm digging out on old question as no solution came out. How to limit page pagination I'm looking for a way to limit pages on homepage and categories (archive.php). I have around 200k posts spread ...
0
votes
0answers
12 views

Next and Prev Post for sub or child category at single-page?

I have category-country.php page and also I have single-country.php where i need to place a next and prev post with in same country that I have different project at country category having USA, China, ...
-1
votes
0answers
9 views

Wordpress Yootheme Pagination on Custom Template Page

I registered a Custom Post Type named Projects. I echoed all the articles in a page with a custom template: <?php /* Template Name: Progetti Template */ get_header(); if ($theme->get('...
1
vote
1answer
56 views

Page not found when clicking on pagination tab

I have a category page and I am getting some issues on pagination. When I click on NEXT PAGE then I am getting Oops! That page can’t be found. and the URL is showing http://example.com/category/...
0
votes
0answers
21 views

How do I remove the pagination terms after a single URL?

Here is a single URL 10stuffs(dot)com/technews. and it also displays the result when we add pagination terms like 10stuffs(dot)com/technews/page/2. I just want to keep the URL like this 10stuffs(dot)...
1
vote
4answers
468 views

Pagination is not working in custom post type

I want to add pagination in single page of custom post type. This is the code for single page (custom post type): <?php $paged = get_query_var('paged') ? get_query_var('paged') : 1; $args ...
0
votes
1answer
482 views

Reverse ordered pagination on home page

Use on the blog reverse pagination. The question arose. How to make a home page is not the first? Need to break the link Home = First page and make a connection Home = Last page. Home should be the ...
0
votes
2answers
78 views

Distribute Gallery Images Every nth in Loop

I have added an acf image gallery for archive terms and I would like to take those images and insert one image from the gallery every 3 posts in the term archive. This is what I have so far but I am ...
0
votes
0answers
9 views

Pagination-url on frontpage, but no pagination visible or available

I have some projects, one of them is https://mhe.dk, where a customer has events, made with a custom post-type. If you visit the program-page (https://mhe.dk/program), you have some pagination that ...
0
votes
1answer
605 views

Pagination using paginate_links

I am using the built in paginate_links function and setting formatparameter to the default value: '?paged=%#%' . For some reason, it keeps redirecting to a different formatted url. For example, when I ...
-1
votes
1answer
13 views

change pagination url

Currently I’m having URL for pagination pages as: http://www.example.com/category_name/page/2 But I need to change this URL structure as: http://www.example.com/category_name/?page=2 etc. any ...
-1
votes
1answer
32 views

Pagination is not working using WP_Query

I have coded for custom post type pagination but it doesn't work. Here is some code for it. <?php global $wpdb; $userid = get_current_user_id(); $userData = get_user_meta($userid , 'referat', true)...
0
votes
0answers
24 views

how to add pagination to a popular post custom page?

I want to add pagination to my custom page in a popular post, this is my coding. <div class="contentpost"> <div id="rls" class="lr"> <?php $popularpost = new WP_Query(...
-1
votes
1answer
60 views

Next and Previous Pagination button not displaying in WordPress

I have more than 15 posts and I am displaying only 6 per page load and remaining will display after the click on the pagination but the issue is I am not getting my pagination. I am using below code ...
0
votes
1answer
520 views

Paginate Links in Wp Query Shortcode

so been looking around for this answer, but no go -- basically i have a WP Query that is incased in a shortcode.. I have set up the paginate links function which outputs it on the page. However, the ...
0
votes
1answer
559 views

Pagination not working on my archive page for a custom post type

First off I have a custom post type called events, and I wrote a custom query in in my archive-events.php file. Everything is working great except for the pagination. To trouble shoot I stripped ...
0
votes
1answer
486 views

Add Custom Pagination Permalink

I'm trying to create a page with multiple loops on it and as such also need multiple pagination. This is proving to be a touch difficult, I've managed to get the links to show correctly by using the ...
1
vote
1answer
1k views

How to add pagination to comments?

I am using wp_list_comments(); function to list all the comments, but I want to add some pagination, for example 10 on one page. I tried "Break comments into pages..." in Discussion panel but it ...
0
votes
1answer
841 views

Problem with custom WP_Query and underlying pagination/posts_per_page

In my category template (category.php) I have the following code: <?php // Setup custom loop -- we need to exclude featured posts from listing so they aren't repeated $paged = get_query_var('paged'...
0
votes
0answers
11 views

kriesi WordPress pagination not working its goes to 404 page

I have Taxonomy with name states and term in that taxonomy California http://crowdupdating.jelingu.com/states/california/page/2/ this is how my pagination link looks the pagination code is in ...
0
votes
0answers
18 views

WP Rest API, reset pagination when fetching posts from a new category

I am using ajax and the Wp Rest API to fetch posts from different categories. When I click on a category link, the posts from that category are loaded into the page. What pagination options do I have ...
1
vote
2answers
650 views

get_next_posts_link not working without parameter max_num_pages

I have a custom search page (searchpage.php) using pagination, and I am tring to add lines like below dynamically to my header.php inside <head></head> tag for better pagination SEO. <...
0
votes
2answers
926 views

Adding pagination to a custom archive template

I'm trying to add pagination to my archive template. If I use the same code as on my main blog template it doesn't filter results based on the tag in the URL, instead it simply shows all posts. ...
0
votes
1answer
588 views

Changing post per page causing 404 for pagination. Need a redirect htaccess rule

i changed my wp theme and i changed the "post per page" wp setting on "reading"now because i want to display more posts on the archives pages. i m using pagination on the archives so a lot of pages ...
0
votes
1answer
649 views

How to get all images in Media Gallery with pagination?

I want to get all images in the image gallery with pagination so that I can use infinite-scroll with it. The infinite scroll works but it's taking the posts' number of post, not the images. That ...
0
votes
1answer
591 views

How to fix blank pagination links?

I am working on a Wordpress blog that has what appears to be custom pagination for the posts. As you can see here the correct amount of links are being rendered at the bottom of the page, however ...
0
votes
1answer
678 views

Style first 3 posts differently and use a 2nd loop to get rest of posts / offset and pagination broken

I'm working on a theme and I am having trouble with loops/pagination breaks when using an offest. I looked online and tried to use only 1 loop (per this post) but I'm having trouble making it work. I ...
1
vote
0answers
105 views

How to add pagination to wpbakery grid?

I have a theme with wpbakery page builder. I made a page to display blog posts using wpbakery grid. But I would like to display 5 posts per page and to use ajax pagination. I display 5 posts per page ...
0
votes
1answer
1k views

Count posts for pagination

I'm doing the pagination for a web. < Previous (pagenumber) Next > is easy, already done. But now I need to add a selector to go to a page directly (ex: to page 7), to do so, I need to know how ...
4
votes
2answers
4k views

Display all posts from all categories with pagination

Alright, this might be a tricky one to explain but I'll do my best. At the front page I want to display all the posts from all the categories. However I want them to be divided. Take this for an ...
0
votes
1answer
785 views

Wordpress pagination not returning posts on second page

I've got a page where I only want to display one post per page with pagination at the bottom to go to the next/ previous post. This is my code: <?php $paged = ( get_query_var( 'paged' ) ) ? ...
0
votes
1answer
43 views

Remove 'page-numbers' class from prev and next tags

I'm converting a template to WordPress theme and i need to change some css classes. The WordPress function paginate_links generates this markup: <ul> <li><a class="prev ...