wp_link_pages(‘next_or_number=next’) doesn’t work on home.php
-
The frontpage of my blog uses the template home.php. It shows the latest post. I use <?php wp_link_pages(”) ?> for navigation between pages in the post (using the <!–nextpage–> tag).
The weird thing is: <?php wp_link_pages(‘next_or_number=number’) ?> works fine, but <?php wp_link_pages(‘next_or_number=next’) ?> doesn’t show anything.
I use the function <?php wp_link_pages(‘next_or_number=next’) ?> on single.php and page.php templates as well, were it works fine.
This is my code:
<?php /* Template Name: Home */ ?> <?php get_header(); ?> <div id="page"> <?php include (TEMPLATEPATH . "/sidebar.php"); ?> <?php if (have_posts()) : query_posts('showposts=1'); while (have_posts()) : the_post(); ?> <div id="date"> <div class="month"><?php the_time('M') ?></div> <div class="day"><?php the_time('d') ?></div> </div> <h2><?php the_title(); ?> <a class="comments-link" href="#comments" title="<?php comments_number('Geen reacties','1 reactie','% reacties'); ?>">(<?php comments_number('0','1','%'); ?>)</a></h2> <div class="clearer"></div> <?php wp_link_pages('next_or_number=next') ?> <div class="entry"> <?php the_content('Lees verder » '); ?> </div> <div class="clearer"></div> <?php $wp_query->is_single = true; ?> <?php comments_template(); ?> <?php endwhile; else: ?> <h2 class="center">Niet gevonden</h2> <?php endif; ?> <?php include (TEMPLATEPATH . "/footer.php"); ?>
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
- The topic ‘wp_link_pages(‘next_or_number=next’) doesn’t work on home.php’ is closed to new replies.