我犯了一個頁面,顯示職位,但分頁不出現(1,2,3等)分頁不工作
這是代碼:
<div class="browse-content">
<div class="container">
<h2><?php echo wp_count_posts()->publish; ?> Movies Found</h2>
<section>
<div class="row">
<ul>
<?php
$paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
$args = array(
'posts_per_page' => 3,
'paged' => $paged
);
$the_query = new WP_Query($args);
?>
<?php while ($the_query -> have_posts()) : $the_query -> the_post(); ?>
<?php include '_includes/items/item_2.php';?>
<?php endwhile; wp_reset_postdata();?>
</ul>
</div>
</section>
<div class="pagination"><?php novavideo_theme_pagination(); ?></div><!-- .pagination -->
</div>
</div>
</div>
我搜索了無處不在,但我沒有找到答案...
有人可以幫助我嗎?
你可以檢查當前的'發佈ID <分頁* posts_per_page'和'發佈ID =>分頁* posts_per_page'。 – DaMaGeX
請分享您用於此功能的代碼:novavideo_theme_pagination(); –