From ec9f6d34cb83f23088a9b0634be42bebcf83df52 Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Fri, 11 Jun 2010 17:49:35 +0000 Subject: [PATCH] Don't use deprecated functions. props filosofo, fixes #13854. git-svn-id: https://develop.svn.wordpress.org/trunk@15229 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/deprecated.php | 4 ++-- wp-includes/query.php | 4 ++-- wp-includes/theme-compat/sidebar.php | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/wp-includes/deprecated.php b/wp-includes/deprecated.php index 25532a17b3..ec5a923278 100644 --- a/wp-includes/deprecated.php +++ b/wp-includes/deprecated.php @@ -2543,7 +2543,7 @@ function is_post_type( $post_type ) { */ function is_taxonomy( $taxonomy ) { _deprecated_function( __FUNCTION__, '3.0', 'taxonomy_exists()' ); - return taxonomy_exists( $post_type ); + return taxonomy_exists( $taxonomy ); } /** @@ -2562,4 +2562,4 @@ function is_taxonomy( $taxonomy ) { function is_term( $term, $taxonomy = '', $parent = 0 ) { _deprecated_function( __FUNCTION__, '3.0', 'term_exists()' ); return term_exists( $term, $taxonomy, $parent ); -} \ No newline at end of file +} diff --git a/wp-includes/query.php b/wp-includes/query.php index f39354ada5..cf3cc1e29b 100644 --- a/wp-includes/query.php +++ b/wp-includes/query.php @@ -1972,7 +1972,7 @@ class WP_Query { $whichcat .= " AND $wpdb->term_taxonomy.taxonomy = 'post_tag' "; $include_tags = "'" . implode("', '", $q['tag__in']) . "'"; $whichcat .= " AND $wpdb->term_taxonomy.term_id IN ($include_tags) "; - $reqtag = is_term( $q['tag__in'][0], 'post_tag' ); + $reqtag = term_exists( $q['tag__in'][0], 'post_tag' ); if ( !empty($reqtag) ) $q['tag_id'] = $reqtag['term_id']; } @@ -2000,7 +2000,7 @@ class WP_Query { if ( in_array($item, $tagin) && empty($q['cat']) ) continue; // We should already have what we need if categories aren't being used if ( $item != 'category__and' ) { - $reqtag = is_term( $q[$item][0], 'post_tag' ); + $reqtag = term_exists( $q[$item][0], 'post_tag' ); if ( !empty($reqtag) ) $q['tag_id'] = $reqtag['term_id']; } diff --git a/wp-includes/theme-compat/sidebar.php b/wp-includes/theme-compat/sidebar.php index 9d59359bd7..d2c97277a5 100644 --- a/wp-includes/theme-compat/sidebar.php +++ b/wp-includes/theme-compat/sidebar.php @@ -41,7 +41,7 @@ _deprecated_file( sprintf( __( 'Theme without %1$s' ), basename(__FILE__) ), '3.

%2$s blog archives for the year %3$s.'), get_bloginfo('url'), get_bloginfo('name'), get_the_time('Y')); ?>

-

%2$s blog archives for ‘%3$s’. If you are unable to find anything in these search results, you can try one of these links.'), get_bloginfo('url'), get_bloginfo('name'), wp_specialchars(get_search_query(), true)); ?>

+

%2$s blog archives for ‘%3$s’. If you are unable to find anything in these search results, you can try one of these links.'), get_bloginfo('url'), get_bloginfo('name'), esc_html( get_search_query() ) ); ?>

%2$s blog archives.'), get_bloginfo('url'), get_bloginfo('name')); ?>