Ticket #18752: 18752.5.diff
File 18752.5.diff, 749 bytes (added by , 12 years ago) |
---|
-
wp-includes/link-template.php
122 122 $cats = get_the_category($post->ID); 123 123 if ( $cats ) { 124 124 usort($cats, '_usort_terms_by_ID'); // order by ID 125 $category = $cats[0]->slug; 126 if ( $parent = $cats[0]->parent ) 125 $category_object = get_term( apply_filters( 'post_link_category', $cats[0], $cats, $post ), 'category' ); 126 $category = $category_object->slug; 127 if ( $parent = $category_object->parent ) 127 128 $category = get_category_parents($parent, false, '/', true) . $category; 128 129 } 129 130 // show default category in permalinks, without