link_pages

Print list of pages based on arguments.

Description

(string) link_pages( $before = '<br />', $after = '<br />', (string) $next_or_number = 'number', (string) $nextpagelink = 'next page', (string) $previouspagelink = 'previous page', , (string) $more_file = '' ); 

Returns (string)

Parameters (7)

0. $before — Optional. (string) => '
'
The before.
1. $after — Optional. (string) => '
'
The after.
2. $next_or_number — Optional. (string) => 'number'
The next or number.
3. $nextpagelink — Optional. (string) => 'next page'
The nextpagelink.
4. $previouspagelink — Optional. (string) => 'previous page'
The previouspagelink.
5. $pagelink — Optional. (string) => '%'
The pagelink.
6. $more_file — Optional. (string) => ''
The more file.

Usage

  1. if ( !function_exists( 'link_pages' ) ) { 
  2. require_once ABSPATH . WPINC . '/deprecated.php'; 
  3.  
  4. // The before. 
  5. $before = '
    '; 
  6.  
  7. // The after. 
  8. $after = '
    '; 
  9.  
  10. // The next or number. 
  11. $next_or_number = 'number'; 
  12.  
  13. // The nextpagelink. 
  14. $nextpagelink = 'next page'; 
  15.  
  16. // The previouspagelink. 
  17. $previouspagelink = 'previous page'; 
  18.  
  19. // The pagelink. 
  20. $pagelink = '%'; 
  21.  
  22. // The more file. 
  23. $more_file = ''; 
  24.  
  25. // NOTICE! Understand what this does before running. 
  26. $result = link_pages($before, $after, $next_or_number, $nextpagelink, $previouspagelink, $pagelink, $more_file); 
  27.  

Defined (1)

The function is defined in the following location(s).

/wp-includes/deprecated.php  
  1. function link_pages($before='<br />', $after='<br />', $next_or_number='number', $nextpagelink='next page', $previouspagelink='previous page',  
  2. $pagelink='%', $more_file='') { 
  3. _deprecated_function( __FUNCTION__, '2.1.0', 'wp_link_pages()' ); 
  4.  
  5. $args = compact('before', 'after', 'next_or_number', 'nextpagelink', 'previouspagelink', 'pagelink', 'more_file'); 
  6. return wp_link_pages($args);