Finally I’ve figured out the correct coding for this problem:
<?php
$paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
$wp_query = new WP_Query();
$wp_query->query('tag=concurs&posts_per_page=".get_option("posts_per_page').'&paged=' . $paged);
?>
<?php if ($wp_query->have_posts()) : ?>
<?php while ( $wp_query->have_posts() ) : $wp_query->the_post(); ?>
[code for title, author, category, meta-info etc]
<?php endwhile; ?>
<div class="next-prev"><?php posts_nav_link( ' ', '<img src="' . get_bloginfo('stylesheet_directory') . '/img/pagina-precedenta.png" align="left" />', '<img src="' . get_bloginfo('stylesheet_directory') . '/img/pagina-urmatoare.png" align="right" />'); ?></div>
<?php endif; ?>
Related Posts:
- Why is my pagination /page/2 taking me to index.php?
- Function the_posts_pagination() not compatible with WP_Query arguments
- Filter products on category AND tag
- adding pagination to a foreach loop in wordpress
- duplicated posts when using pagination
- paginate_links appearing on page but it doesn’t actually paginate – pagination on a static page with a dynamic `post_type` argument on a static page
- wordpress pagination wont render on custom page template even though its right under the loop like the documentation says so
- Pagination of custom page with custom fields query
- Only show tag with the same id as the post
- pre_get_posts pagination not working
- How can I have sticky posts while ALSO showing posts from a specific category using one WP_Query?
- Pagination repeating posts on search results
- Pagination not working on archive.php template?
- WordPress Sub Category Archive, Show Extra Empty Page Number in Pagination
- WP_query pagination on frontpage
- Get posts that match defined arrays of tags
- Pagination unique to a widget
- Pagination inside the blog page not working
- Order posts by tags count?
- Pagination for Category does not work
- Fix wp_term_relationships slow query in get_posts
- Why pagination is not working with tax_query param?
- Pagination on archive.php not working?
- paginate_links method doesn’t show second page of my custom wp_query
- Wp_Query Post per page not working?
- Pagination Shows Up But Won’t Work on Custom Gallery Page
- Custom Query Pagination not working on static front page
- getting posts by tags
- Search with WP_Query, but ignore href URLs in anchor tags?
- 404 page on custom search pagination
- WordPress search page pagination displaying but not functional
- Show posts from categories instead of tags
- Paging works correctly on local version, but not live?
- Pagination not working in custom loop WP_Query
- pagination functions are not working
- Showing the correct number of posts_per_page when avoiding the use of post__not_in
- post_type not working when tag__in is present?
- Related Post by Tags Code
- WordPress pagination not returning posts on second page
- Paginated Post List on Front Page
- Paginate nested query of child posts
- How to set up pagination for a custom loop on a global template (author.php, tag.php, archive.php?)
- Exclude all tagged posts from WP_Query loop
- I cannot get tax_query in get_posts() to work with custom taxonomy
- WordPress custom query by archive title
- How to create page that lists tags by initial letter?
- Problem with custom WP_Query and underlying pagination/posts_per_page
- Combine WP_Query with array of custom data to single loop without breaking the pagination
- Pagination in WP_Query?
- 2 Loops on one page – pagination of 2nd loop ignore array of excluded posts
- Random posts in WP_Query when searching by tag
- Pagination returns 404 after page 20
- 3 wp_query on one page with pagination for last query
- Custom pagination (Title, date and teaser)
- WP_Query with Pagination and orderby meta_value_num showing duplicates
- custom query – offset to pagination
- Archive – Show Page Month Headers
- previous_posts_link not working in WordPress pagination
- Issue attempting a wp_query_posts with tags
- Query post Pagination Problem
- Pagination not working with WP_QUERY
- Add pagination to table generated by wp_query
- Pagination for custom query throws 404 errors on last pages [duplicate]
- WP_Query with meta_value_num and meta_query not paged correctly
- Pagination is not working on custom query inside a custom home page template
- Pagination in custom query in a category page
- Horizontally paginate through sets of blog posts?
- Pagination not working in some author pages
- Pagination error WordPress multiple loop
- Pagination with WP_Query not working
- How to add archives (with pagination) to page template?
- No content found on page 2 of pagination with 1 post per page
- Comments orderby comment date not working
- Switched from query_posts to wp_query, pagination no longer working
- What is wrong with this pagination code?
- wp_query pagination links producing 404
- Pagination With Custom WP Query not functioning
- Can’t get pagination to work with this WP_Query loop
- Pagination in custom loop [duplicate]
- Ordering Custom WP_Query loop by meta key value with pagination
- Query specific number of posts for each post type in specific order
- Limit Tags display and ad Drop Down Menu
- Loop being strainge
- Why won’t my paged wp_query work? [duplicate]
- Custom query (author is post_author or meta co_author) with Pagenavi pagination
- WP_Query breaks pagination
- Pagination in custom query not working [duplicate]
- Pagination doesn’t work for home page custom post type query
- Loop issues when creating custom query for media uploader
- Query multiple taxonomies with pagination
- Pagination in WP query with transient API
- paginate_links() on page (shortcode output)
- paginate_links() with Custom Taxonomy
- Multiple loops on index page with sticky post and pagination
- Pagination problem with multiple loops on the same page
- WordPress Post Looping? [duplicate]
- Pagination not working in secondary query
- WP Paginate not working properly
- Paginate wp_query while utilizing post__not_in
- Get next post when using pagination with WP_Query?