1
vote
1answer
35 views

I'm having some issues with previous_post_link() and next_post_link()

I've been developing a Wordpress site lately and have come across an issue. I need the user to be able to navigate between posts, I'm using the standard Wordpress functions previous_post_link() and ...
1
vote
1answer
75 views

Start post pagination at 0 instead of 1

Is it possible to start post pagination count at zero instead of 1? I want the URLs to be like this: ../page (Foreword) ../page/1 (Chapter 1) ../page/2 (Chapter 2) But by default the ...
0
votes
1answer
30 views

Show number of posts AND number on current page

I know how to show the total number of posts in a site, but is there a way to show the number of posts the page you're on is displaying? For example, I want to show this at the bottom of each of my ...
0
votes
1answer
24 views

Post of a specific category - not to be seen in paging previous/next post

i have a specific post category, eg. id=x which is not shown in category list. These posts are password protected and should be visible only to those provided with the link. However current version ...
0
votes
2answers
233 views

Pagination not working on Custom Page Template

I searched a lot on this but I can't figure out why my code is not working. I published a page with slug "blog" that uses a custom built template "page-blog.php" that I build from editing the ...
0
votes
1answer
57 views

Add wp-link-pages to post

I am trying to add wp-link-pages function to my post where I have images split into many pages in that single post. I already have next and prev button whose functionality is written javascript. I ...
0
votes
0answers
16 views

Post Pagination Titles

what I'm trying to do is set a different title for each page of the post pagination. So for example example.com/post-title/ title in the header is "Post Title" example.com/post-title/2/ title in ...
0
votes
0answers
27 views

wordpress paginate, link to the right page

I have posts that I paginate, instead of showing them on their single post page I would like to show them on the archive page. I've built my own archive-page with custom functions. I just added ...
0
votes
0answers
73 views

Pagination working locally but not on live site

I have a loop on my single.php page like this:- <?php if (have_posts()) : ?> <?php $paged = get_query_var( 'paged' ) ? get_query_var( 'paged' ) : 1; ?> <?php $this_post = ...
5
votes
2answers
522 views

WP_Query Pagination on single-custom.php

What I am looking to do: Setup WP_Query pagination in a single-custom-post-type.php template file What I have done 1) Created a post type called "authors". Each post within that post type is an ...
1
vote
1answer
25 views

How safe is renovating $wp_query when doing WP_Query pagination in Page Template

With a lot of search and trial&error, I's unable to do the pagination in a custom page template. I's not actually tired, but frustrated, why the most common err issue is not explained in a way so ...
1
vote
0answers
22 views

Start WP Pagination From Number 1 in URL

I am using this code to paginate gallery post type images: $images = get_posts(array( 'post_type' => 'attachment', 'post_status' => 'inherit', 'post__in' => $image_ids, 'orderby' => ...
0
votes
1answer
40 views

Pagination and Related Posts

Is it possible to use pagination with the following related posts code, which is embed in single.php of my theme. <?php // for use in the loop, list 5 post titles related to first tag on ...
0
votes
1answer
23 views

Pagination for custom query won't let me back on page 1

I have a custom query … <?php /** * The loop that displays the posts. */ ?> <ul class="post-items"> <?php $args = array( 'post_type' => array('post', 'wr_raffle'), ...
0
votes
0answers
36 views

Make a paginated article (for easier reading on mobile)

I'm looking for some plugin, or perhaps more likely some Javascript package that will make me do something like mobil.idg.se on a phone (select a story, then swipe sideways to read the next part of ...
0
votes
1answer
399 views

Pagination for Pages and Posts

I want to use Pagination throughout a new theme but am having trouble getting it to work correctly. I am using some code within my functions.php file and then calling that function. It works on the ...
0
votes
1answer
965 views

JetPack Infinite Scroll not working on custom theme

I have a custom theme where I've tried to integrate the Infinite Scroll option within JetPack. Per this article, I've added the following code to functions.php (in addition to activating the module) - ...
-3
votes
1answer
95 views

Newer/Older posts links display same posts on every page

I am using a plugin called "Types" to generate custom post types for drink/food recipes. I want to show booth drink and food recipes on the same page. The posts are displaying fine, but for some ...
0
votes
2answers
335 views

Should $found_posts be returned as string in 'found_posts' filter hook?

In general a function that hooks into the found_posts filter looks like this: add_filter( 'found_posts', 'adjust_offset_pagination', 10, 2 ); function adjust_offset_pagination( $found_posts, $query ) ...
0
votes
1answer
127 views

how to show posts on different pages if number of post per page is one

i have a category named "services". when "our services" is clicked control go to category.php file. in that i need to show all the posts in that service category. i can show all of them in a single ...
0
votes
0answers
62 views

Numeric Pagination Not working

I wrote a function that does (it's unrefactored, bare with me): protected function _index_numeric_posts_pagination($options){ global $wp_query; $total = ...
0
votes
0answers
12 views

Older/Newer post links display the same posts [duplicate]

I am trying to code my loop so that there are Older posts and Newer posts links below the loop, currently I am using the wp-pagenavi plugin for this but when I click the "previous posts" link, it ...
0
votes
0answers
61 views

How do I paginate posts page with $wpdb?

I am using this to get the posts: (...) if ( empty( $categories_defined) ) { $posts = get_posts($args); } else { global $wpdb; $posts = $wpdb->get_results( $wpdb->prepare( "SELECT * ...
0
votes
1answer
411 views

Archive Page for Custom Post Type is not Working

I have registered a custom post type "tutorials" with the following snippet. <?php /* Template Name: Tutorial Archive */ get_header(); ?> <div id="content"> <div ...
0
votes
0answers
84 views

Can't get pagination to work

I'm trying to create pagination on a blog post page where one page displays 13 blog posts and then displays some links to go to another page. Now just to get it working, I'm using this code: <?php ...
0
votes
1answer
3k views

How to display a paginated list of posts from one category on a page? [duplicate]

I'm trying to use the code from this page: Display Blog Posts on any Page (with navigation) http://digwp.com/2013/01/display-blog-posts-on-page-with-navigation/ My goal is to make pages that display ...
0
votes
1answer
59 views

How to inject a post within a loop

I'm trying to inject a post while the loop is running. This post will be injected on a condition, so if(x == j){ //inject post here } I see this would seem easy to do, but i have a posts_per_page ...
0
votes
1answer
68 views

Customizing Comments on Posts

I have implemented custom code for generating comments on post page using callback function in functions.php. function MYTHEME_comment($comment, $args, $depth) { $GLOBALS['comment'] = $comment; ...
0
votes
1answer
228 views

Pagination for normal (standard) posts on a page with a custom loop?

probably a rather straight forward question. my "homepage" is not the blog-page. I have a page-template named page-knowledge.php which has the following loop on it. <?php echo '<ul ...
2
votes
2answers
3k views

Next_posts_link() works only with original $wp_query

I've got custom template that I want to display paged blog posts. This is the beginning of my file: $wp_query = new WP_Query($args); if($wp_query->have_posts()){ ...
1
vote
1answer
1k views

Load posts into sidebar and paginate via ajax?

Is it possible to paginate, or load the next / previous posts in the sidebar without messing with the entire page pagination? Such as AJAX? Right now I'm querying custom post type posts to load the ...
2
votes
2answers
98 views

Different amount of posts on homepage than paged pages

I've done some searches here and on Google but everything I'm finding isn't working correctly. I was hoping to post my code here and get help with where I'm going wrong. On the index page of my ...
5
votes
1answer
82 views

Allow variable amount of comments before pagination

There is an option in the admin settings allowing you to define how many comments should be listed before creating a new page for the next ones. I would like to have the same number of comments for ...
0
votes
1answer
243 views

Converting multiple loops into one single loop with pagination

I am using Isotope jquery plugin to filter/sort posts in Wordpress but to correctly filter the posts into the right order I have needed to output each category one after the other. To do this I've ...
2
votes
1answer
458 views

pagination hook doesn't work with search results

I use my custom Pagination function on my web site; #Pagination function pagination($prev = '«', $next = '»') { global $wp_query, $wp_rewrite; ...
1
vote
1answer
326 views

Setting pagination for images attached to a post

I am trying to figure out how to paginate a post for it's images. I have a custom post type set up to act like a gallery - images only. And would like to paginate the images. I am having a hard time ...
0
votes
1answer
65 views

how to add pagination to the organize series plugin

I'm thinking of using the organize series plugin for posts featuring learning videos. As they are step1, step2 etc I'd rather use pagination instead of the next/previous links. Does anyone know how ...
0
votes
1answer
418 views

Total number of posts in query (category/tag/author/search results/main page…)

I want to know the total number of posts from the category/tag/author/search result that I am actually seeing. Say for example I am in the main page. If my posts_per_page are 10 and my pagination ...
0
votes
1answer
2k views

Custom Post Type Pagination 404 Error (if paged>=2) [duplicate]

I coded a WordPress theme. I added a Photo Gallery with custom post type. But if paged>=2, it gives 404 error. If you open my web site link and click Tümünü Göster (Show All) button, you can test ...
0
votes
1answer
193 views

How to get pagination working with “Pending” Posts

I'm working on a site that allows users to browse through pending posts/content on the front-end. However, I can't seem to get pagination working with those posts. I've got a custom query that ...
1
vote
1answer
1k views

Custom Post Type Pagination Doesn't Work in Wordpress 3.4

I have a problem when using Wordpress 3.4. My "Products" custom post type pagination doesn't work. Here is the code I use $paged = (get_query_var('paged')) ? get_query_var('paged') : 1; $loop = new ...
1
vote
2answers
666 views

wordpress post pagination with image buttons?

I'm trying to make a post pagination like this: button left image | 1 2 3 4 5 |button right image but I can't get it work. I've tried: <?php ...
2
votes
1answer
330 views

How can I get all posts data from within a paginated search result?

Let's say I'm doing a search on my site, and get 50 posts as a result. The pagination is set to 10 posts per page, so I have 5 pages of results. When I'm on the first page of results, if I inspect ...
1
vote
1answer
509 views

Use two different post_per_page limits with infinite scroll

I have one loop on my homepage that I use infinite scroll to paginate. To keep the load time of the homepage down, I want to load a smaller initial amount than when the infinite scroll is triggered ...
0
votes
2answers
282 views

Why won't pagination work?

I am using a page template with code to display all blog posts: <?php /* Template Name: Blog */ ?> <?php get_header(); ?> <div id="main"> <?php // ACF Page number variable ...
0
votes
2answers
537 views

Getting content from a single *page* of a post

What function can I use to fetch content of a single page within a post? Let's say I want to split my post into 5 pages - how can I get content of, say, page 3? Can't seem to find this in Codex...
0
votes
2answers
1k views

Pagination for posts inside a specific category

I have a FAQ category and there are posts in that category I want to add pagination to that category only, not the other category in my wordpress. In short giving pagination to selected category for ...
2
votes
1answer
4k views

Change Posts per page count

In the wordpress settings => Reading => Blog pages show at most [input field] posts I have it set to 3 posts at the moment. On my index, date archives, tag archives, category archives, search ...
0
votes
1answer
97 views

Display “Post 2 of 4” on single post page?

I have a custom post type called Projects. When viewing a single 'project' post I have next/prev buttons to navigate through them. I also want to display text saying "Project 2 of 4" or ideally ...
1
vote
2answers
1k views

Pagination on single post page?

I've found many pagination tutorials/plugins that work on pages displaying a list of posts such as index.php E.g. - ...