WordPress.org

Make WordPress Core

Changeset 4864


Ignore:
Timestamp:
02/02/2007 04:39:04 PM (12 years ago)
Author:
ryan
Message:

Check page ID only if is_page. fixes #3049

File:
1 edited

Legend:

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

    r4748 r4864  
    274274
    275275    $output = '';
     276    $current_page = 0;
    276277
    277278    // sanitize, mostly to keep spaces out
     
    289290
    290291        global $wp_query;
    291         $current_page = $wp_query->get_queried_object_id();
     292        if ( is_page() )
     293            $current_page = $wp_query->get_queried_object_id();
    292294        $output .= walk_page_tree($pages, $r['depth'], $current_page, $r);
    293295
Note: See TracChangeset for help on using the changeset viewer.