[Plugin: WP-PageNavi] where to place wp_pagenavi(); in custome loop?
-
hi
where in the code below I should place wp_pagenavi(); to make it work?
Thank you
R.
function list_all_posts() { if (is_page('video')) { $paged = (get_query_var('paged')) ? get_query_var('paged') : 1; $args=array( 'orderby' => 'date', 'order' => 'DESC', 'category_name' => 'blog', 'posts_per_page' => 3, 'post_status' => 'publish', 'paged' => $paged, ); $archive_query = new WP_Query($args); echo "<ul>\n"; while ($archive_query->have_posts()) : $archive_query->the_post(); echo '<li><a href="' . get_permalink() . '" rel="bookmark">' . get_the_title() . "</a></li>\n"; endwhile; echo "</ul>\n"; wp_pagenavi(); wp_reset_query(); } }
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘[Plugin: WP-PageNavi] where to place wp_pagenavi(); in custome loop?’ is closed to new replies.