WordPress.org

Ready to get started?Download WordPress

Forums

WordPress Instagrabber
[resolved] Page Navigation (8 posts)

  1. Mic_H
    Member
    Posted 1 year ago #

    Using the follow code outputs 9 images (Blog pages shown at most is set to 9).

    <?php query_posts('post_type=images'); ?>
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    
    <div class="post-image" id="post-<?php the_ID(); ?>"><?php the_content(); ?></div>
    
    <?php endwhile; ?>
    <?php else: ?>
    <h2 class="main-h2">Images</h2>
    <h2>No Content</h2>
    <?php endif; ?>

    Have tried using page navigation like I have on my post page to navigate to the next 9 images but I can't get it to work. Any suggestions?

    http://wordpress.org/extend/plugins/instagrabber/

  2. Johan Ahlbäck
    Member
    Plugin Author

    Posted 1 year ago #

  3. Johan Ahlbäck
    Member
    Plugin Author

    Posted 1 year ago #

    Marked resolved as it is a duplicate question

  4. Mic_H
    Member
    Posted 1 year ago #

    Hi Johan,

    I have tried doing what you suggested but have had no look. When I click next to see the rest of the posts I get taken to another page of my site. I thought it might have been down to another plugin but after deactivating the all of the others I am still getting taken to the wrong page.

    My URL reads http://www.site.com/images/2 but it is not the second page of images but another page where I plan on displaying videos.

    Any ideas what might be causing this would be appreciated but if not I will be fine to just display more images on the page than I had planned.

    Thanks

  5. Johan Ahlbäck
    Member
    Plugin Author

    Posted 1 year ago #

    the url should look like this http://www.site.com/images/page/2/
    are you using
    <?php next_posts_link('Older Entries »', 0); ?>
    and
    <?php previous_posts_link('« Newer Entries', 0) ?>

  6. Mic_H
    Member
    Posted 1 year ago #

    I've tried a few different ways. After trying that my URL now reads images/page/2 but I am still being sent to one of my other pages on the site.

    I'm guessing this is more of a problem with my custom theme.

  7. Johan Ahlbäck
    Member
    Plugin Author

    Posted 1 year ago #

    I think so. You if you add the right params you should be able to use page navigation on that page.

  8. Mic_H
    Member
    Posted 1 year ago #

    Appreciate your help. I'll have to come back to this and try figure it out.

    I will let you know if i figure out why I am having this problem.

    Thanks

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic