• Has anyone tried using pagenavi on the sidebar?
    Here’s my issue. I have a sidebar.php that contains a query of a category with page navi.If you select a post on the category (via sidebar) the content loads on the right side (using single.php) however the single.php has to load (get_sidebar(); to load the same query on the left side. The problem is it always goes back to page1 even though you select a post on page2 or page3.
    I believe my issue happens to be because I am calling the sidebar again on the single.php and reloads it’s query again. Is there a way to maintain the result of the query.

Viewing 1 replies (of 1 total)
  • Thread Starter jjoves

    (@jjoves)

    How do you preserve a value of a query and calling the result without reloading query.

    Original Query
    <?php query_posts($query_string . '&cat='.NEWS. '&posts_per_page=5'.'&paged='. get_query_var('paged')); ?>

    ‘<?php if (is_single()) : ?>
    <?php if (in_category(NEWS)) : ?>
    LOAD RESULT OF QUERY
    <?php endif; ?>’

Viewing 1 replies (of 1 total)
  • The topic ‘PageNavi on sidebar issue’ is closed to new replies.