Make WordPress Core

Ticket #15963: 15963.2.diff

File 15963.2.diff, 429 bytes (added by MikeHansenMe, 12 years ago)

checks the status of the parent page before adding it to uri

  • wp-includes/post.php

     
    34423442        $uri = $page->post_name;
    34433443
    34443444        foreach ( $page->ancestors as $parent ) {
     3445                /* check that the page is publish status*/
     3446                if("publish"  ==  get_post_status( $parent ))
    34453447                $uri = get_post( $parent )->post_name . "/" . $uri;
    34463448        }
    34473449