Changeset 7941
- Timestamp:
- 05/16/2008 03:57:09 AM (17 years ago)
- Location:
- trunk/wp-includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/general-template.php
r7634 r7941 232 232 $post = $wp_query->get_queried_object(); 233 233 $title = strip_tags( apply_filters( 'single_post_title', $post->post_title ) ); 234 } 235 236 // If there's a taxonomy 237 if ( is_tax() ) { 238 $taxonomy = get_query_var( 'taxonomy' ); 239 $tax = get_taxonomy( $taxonomy ); 240 $tax = $tax->label; 241 $term = $wp_query->get_queried_object(); 242 $term = $term->name; 243 if ( 'right' == $seplocation ) 244 $title = "$term $sep $tax"; 245 else 246 $title = "$tax $sep $term"; 234 247 } 235 248 -
trunk/wp-includes/query.php
r7906 r7941 1611 1611 $slug = $this->get('term'); 1612 1612 $term = &get_terms($tax, array('slug'=>$slug)); 1613 if ( is_wp_error($term) )1613 if ( is_wp_error($term) || empty($term) ) 1614 1614 return $term; 1615 $term = $term[0]; 1615 1616 $this->queried_object = $term; 1616 1617 $this->queried_object_id = $term->term_id;
Note: See TracChangeset
for help on using the changeset viewer.