WordPress.org

Make WordPress Core

Changeset 15617


Ignore:
Timestamp:
09/14/2010 04:48:38 PM (8 years ago)
Author:
nacin
Message:

Some docs and corrections to _wp_link_page().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/post-template.php

    r15582 r15617  
    617617}
    618618
     619/**
     620 * Helper function for wp_link_pages().
     621 *
     622 * @since 3.1.0
     623 * @access private
     624 *
     625 * @param $i Page number.
     626 * @return string Link.
     627 */
    619628function _wp_link_page( $i ) {
    620629    global $post, $wp_rewrite;
    621630
    622631    if ( 1 == $i ) {
    623         $url .= get_permalink();
     632        $url = get_permalink();
    624633    } else {
    625634        if ( '' == get_option('permalink_structure') || in_array($post->post_status, array('draft', 'pending')) )
     
    628637            $url = trailingslashit(get_permalink()) . user_trailingslashit("$wp_rewrite->pagination_base/" . $i, 'single_paged');
    629638        else
    630             $url .= trailingslashit(get_permalink()) . user_trailingslashit($i, 'single_paged');
     639            $url = trailingslashit(get_permalink()) . user_trailingslashit($i, 'single_paged');
    631640    }
    632641
Note: See TracChangeset for help on using the changeset viewer.