Make WordPress Core


Ignore:
Timestamp:
08/26/2007 05:18:00 PM (17 years ago)
Author:
ryan
Message:

Display tag name, not slug, in title. Props ionfish. fixes #4812

File:
1 edited

Legend:

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

    r5944 r5945  
    187187                    $category_name = $category_name[count($category_name)-2]; // there was a trailling slash
    188188        }
    189         $cat = get_term_by('slug', $category_name, 'category');
     189        $cat = get_term_by('slug', $category_name, 'category', OBJECT, 'display');
    190190        if ( $cat )
    191191            $title = apply_filters('single_cat_title', $cat->name);
     
    193193
    194194    if ( !empty($tag) ) {
    195         $tag = get_term($tag, 'post_tag');
     195        $tag = get_term($tag, 'post_tag', OBJECT, 'display');
    196196        if ( ! empty($tag->name) )
    197             $title = apply_filters('single_tag_title', $tag->slug);
     197            $title = apply_filters('single_tag_title', $tag->name);
    198198    }
    199199
Note: See TracChangeset for help on using the changeset viewer.