[wp-hackers] Posts 2 Posts: Pagination for connected posts on single post template
Md Mahmudur Rahman
iammahmudur at gmail.com
Fri Jun 28 00:24:08 UTC 2013
If I set the page number as a GET parameter then it works for the first
loop/primary loop and not for the secondary loop. As a result the URL
Here is the response (WP_Query Object) for the first loop:
And here is the response (WP_Query Object) for the second loop:
How can I set the 'page' parameter for the second loop?
On Fri, Jun 28, 2013 at 9:57 AM, J.D. Grimes <jdg at codesymphony.co> wrote:
> Does it work if you add the page number as a GET parameter?
> For Example, http://localhost/artist/artist-name/?page=2
> -J.D. Grimes
> On Jun 27, 2013, at 7:37 PM, Md Mahmudur Rahman <iammahmudur at gmail.com>
> > Hi
> > I have tried that as well. But no luck.
> > The pagination links are part of a secondary loop on a single page
> > template. And I can see that get_query_var('paged') always returning 1.
> > a result the pagination links are not working.
> > Is it possible to paginate through a secondary loop on a *single page
> > template*? For example, on a single page template can I have a URL like
> > below:
> > http://localhost/artist/artist-name/page/2
> > Here is the link for:
> > single-artist.php <
> > loop-artist.php <
> > Pagination code on functions.php<
> > Many thanks.
> > On Thu, Jun 27, 2013 at 11:38 PM, J.D. Grimes <jdg at codesymphony.co>
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
*Md Mahmudur Rahman*
More information about the wp-hackers