Codex tools: Log in / create account
Contents |
Displays page-links for paginated posts (i.e. includes the <!--nextpage--> Quicktag one or more times). This works in much the same way as link_pages(), the difference being that arguments are given in query string format. This tag must be within The_Loop.
<?php wp_link_pages( $args ); ?>
<?php $args = array(
'before' => '<p>' . __('Pages:'),
'after' => '</p>',
'link_before' => ,
'link_after' => ,
'next_or_number' => 'number',
'nextpagelink' => __('Next page'),
'previouspagelink' => __('Previous page'),
'pagelink' => '%',
'more_file' => ,
'echo' => 1 ); ?>
Displays page-links by default with paragraph tags before and after, using Next page and Previous page, listing them with page numbers as Page 1, Page 2 and so on.
<?php wp_link_pages(); ?>
Displays page-links wrapped in paragraph tags.
<?php wp_link_pages('before=<p>&after=</p>&next_or_number=number&pagelink=page %'); ?>
Displays page-links in DIV for CSS reference as <div id="page-links">.
<?php wp_link_pages('before=<div id="page-links">&after=</div>'); ?>
Since: 0.71
wp_link_pages() is located in wp-includes/post-template.php.
the_ID, the_title, the_title_attribute, single_post_title, the_title_rss, the_content, the_content_rss, the_excerpt, the_excerpt_rss, wp_link_pages, next_post_link, next_posts_link, previous_post_link, previous_posts_link, posts_nav_link, sticky_class, the_meta