我在我的WordPress站點上使用wp-paginate插件進行分頁。分頁鏈接顯示正常。問題是每個頁面都顯示一個空白頁面。 我正在使用以下代碼來調用分頁。我是新的WordPress的,所以很抱歉有任何錯誤..wp-paginate()在導航到其他頁面時顯示空白頁
<?php if (have_posts()) : ?>
<?php /* Start the Loop */ ?>
<?php while (have_posts()) : the_post(); ?>
<?php get_template_part('content', get_post_format()); ?>
<?php endwhile; ?>
<?php //twentytwelve_content_nav('nav-below'); ?>
<?php if(function_exists('wp_paginate')) {
wp_paginate();
}
else {
twentytwelve_content_nav('nav-below');
}
?>
您正在使用'get_template_part'函數。你真的有模板「內容」嗎? – STORM