Php Don';不要在wordpress循环中使用上一个和下一个按钮。即使是don';不要给他们看
使用这个简单的代码。但是按钮不显示。。。奇怪的Php Don';不要在wordpress循环中使用上一个和下一个按钮。即使是don';不要给他们看,php,wordpress,Php,Wordpress,使用这个简单的代码。但是按钮不显示。。。奇怪的 <?php if (have_posts()) : while (have_posts()) : the_post(); the_content(); previous_posts_link('« Previous Entries'); next_posts_link('Next Entries »',''); endwhile; endif; ?> <?php
<?php
if (have_posts()) :
while (have_posts()) :
the_post();
the_content();
previous_posts_link('« Previous Entries');
next_posts_link('Next Entries »','');
endwhile;
endif;
?>
<?php
if (have_posts()) :
while (have_posts()) :
the_post();
the_content();
if (is_singular('attachment')) {
// Parent post navigation.
the_post_navigation(array(
'prev_text' => _x('<span class="meta-nav">Published in</span><span class="post-title">%title</span>', 'Parent post link', 'themename'),
));
} elseif (is_singular('post')) {
// Previous/next post navigation.
the_post_navigation(array(
'next_text' => '<span class="meta-nav" aria-hidden="true">' . __('Next', 'themename') . '</span> ' .
'<span class="screen-reader-text">' . __('Next post:', 'themename') . '</span> ' .
'<span class="post-title">%title</span>',
'prev_text' => '<span class="meta-nav" aria-hidden="true">' . __('Previous', 'themename') . '</span> ' .
'<span class="screen-reader-text">' . __('Previous post:', 'themename') . '</span> ' .
'<span class="post-title">%title</span>',
));
}
endwhile;
endif;
?>