]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-includes/deprecated.php
Wordpress 3.1.3
[autoinstalls/wordpress.git] / wp-includes / deprecated.php
index 77c3e1dfe60a2a44b4a1187d7dd37ce52d3f2e09..2300572ef610c421b44faf98915711c6f925a2b4 100644 (file)
@@ -164,10 +164,10 @@ function previous_post($format='%', $previous='previous post: ', $title='yes', $
  * @see next_post_link()
  *
  * @param string $format
  * @see next_post_link()
  *
  * @param string $format
- * @param string $previous
+ * @param string $next
  * @param string $title
  * @param string $in_same_cat
  * @param string $title
  * @param string $in_same_cat
- * @param int $limitprev
+ * @param int $limitnext
  * @param string $excluded_categories
  */
 function next_post($format='%', $next='next post: ', $title='yes', $in_same_cat='no', $limitnext=1, $excluded_categories='') {
  * @param string $excluded_categories
  */
 function next_post($format='%', $next='next post: ', $title='yes', $in_same_cat='no', $limitnext=1, $excluded_categories='') {
@@ -430,7 +430,7 @@ function get_linksbyname($cat_name = "noname", $before = '', $after = '<br />',
  * @return bool|null
  */
 function wp_get_linksbyname($category, $args = '') {
  * @return bool|null
  */
 function wp_get_linksbyname($category, $args = '') {
-       _deprecated_function(__FUNCTION__, '0.0', 'wp_list_bookmarks()');
+       _deprecated_function(__FUNCTION__, '2.1', 'wp_list_bookmarks()');
 
        $defaults = array(
                'after' => '<br />',
 
        $defaults = array(
                'after' => '<br />',
@@ -872,10 +872,10 @@ function permalink_link() {
  * @deprecated Use the_permalink_rss()
  * @see the_permalink_rss()
  *
  * @deprecated Use the_permalink_rss()
  * @see the_permalink_rss()
  *
- * @param string $file
+ * @param string $deprecated
  */
 function permalink_single_rss($deprecated = '') {
  */
 function permalink_single_rss($deprecated = '') {
-       _deprecated_function( __FUNCTION__, '0.0', 'the_permalink_rss()' );
+       _deprecated_function( __FUNCTION__, '2.3', 'the_permalink_rss()' );
        the_permalink_rss();
 }
 
        the_permalink_rss();
 }
 
@@ -892,7 +892,7 @@ function permalink_single_rss($deprecated = '') {
  * @return null|string
  */
 function wp_get_links($args = '') {
  * @return null|string
  */
 function wp_get_links($args = '') {
-       _deprecated_function( __FUNCTION__, '0.0', 'wp_list_bookmarks()' );
+       _deprecated_function( __FUNCTION__, '2.1', 'wp_list_bookmarks()' );
 
        if ( strpos( $args, '=' ) === false ) {
                $cat_id = $args;
 
        if ( strpos( $args, '=' ) === false ) {
                $cat_id = $args;
@@ -2035,7 +2035,7 @@ function get_attachment_innerHTML($id = 0, $fullsize = false, $max_dims = false)
        return apply_filters('attachment_innerHTML', $innerHTML, $post->ID);
 }
 
        return apply_filters('attachment_innerHTML', $innerHTML, $post->ID);
 }
 
-/*
+/**
  * Retrieve bookmark data based on ID.
  *
  * @since 2.0.0
  * Retrieve bookmark data based on ID.
  *
  * @since 2.0.0
@@ -2296,7 +2296,8 @@ function delete_usermeta( $user_id, $meta_key, $meta_value = '' ) {
        else
                $wpdb->query( $wpdb->prepare("DELETE FROM $wpdb->usermeta WHERE user_id = %d AND meta_key = %s", $user_id, $meta_key) );
 
        else
                $wpdb->query( $wpdb->prepare("DELETE FROM $wpdb->usermeta WHERE user_id = %d AND meta_key = %s", $user_id, $meta_key) );
 
-       wp_cache_delete($user_id, 'users');
+       clean_user_cache( $user_id );
+       wp_cache_delete( $user_id, 'user_meta' );
 
        if ( $cur && $cur->umeta_id )
                do_action( 'deleted_usermeta', $cur->umeta_id, $user_id, $meta_key, $meta_value );
 
        if ( $cur && $cur->umeta_id )
                do_action( 'deleted_usermeta', $cur->umeta_id, $user_id, $meta_key, $meta_value );
@@ -2403,7 +2404,8 @@ function update_usermeta( $user_id, $meta_key, $meta_value ) {
        else
                return false;
 
        else
                return false;
 
-       wp_cache_delete($user_id, 'users');
+       clean_user_cache( $user_id );
+       wp_cache_delete( $user_id, 'user_meta' );
 
        if ( !$cur )
                do_action( 'added_usermeta', $wpdb->insert_id, $user_id, $meta_key, $meta_value );
 
        if ( !$cur )
                do_action( 'added_usermeta', $wpdb->insert_id, $user_id, $meta_key, $meta_value );
@@ -2413,6 +2415,31 @@ function update_usermeta( $user_id, $meta_key, $meta_value ) {
        return true;
 }
 
        return true;
 }
 
+/**
+ * Get users for the blog.
+ *
+ * For setups that use the multi-blog feature. Can be used outside of the
+ * multi-blog feature.
+ *
+ * @since 2.2.0
+ * @deprecated 3.1.0
+ * @uses $wpdb WordPress database object for queries
+ * @uses $blog_id The Blog id of the blog for those that use more than one blog
+ *
+ * @param int $id Blog ID.
+ * @return array List of users that are part of that Blog ID
+ */
+function get_users_of_blog( $id = '' ) {
+       _deprecated_function( __FUNCTION__, '3.1', 'get_users()' );
+
+       global $wpdb, $blog_id;
+       if ( empty($id) )
+               $id = (int) $blog_id;
+       $blog_prefix = $wpdb->get_blog_prefix($id);
+       $users = $wpdb->get_results( "SELECT user_id, user_id AS ID, user_login, display_name, user_email, meta_value FROM $wpdb->users, $wpdb->usermeta WHERE {$wpdb->users}.ID = {$wpdb->usermeta}.user_id AND meta_key = '{$blog_prefix}capabilities' ORDER BY {$wpdb->usermeta}.user_id" );
+       return $users;
+}
+
 /**
  * Enable/disable automatic general feed link outputting.
  *
 /**
  * Enable/disable automatic general feed link outputting.
  *
@@ -2501,19 +2528,6 @@ function funky_javascript_fix($text) {
        return $text;
 }
 
        return $text;
 }
 
-/**
- * Generates and displays the RDF for the trackback information of current post.
- *
- * @since 0.71
- * @deprecated 3.0.0
- *
- * @param int $deprecated Not used (Was $timezone = 0)
- */
-function trackback_rdf($deprecated = '') {
-       _deprecated_function( __FUNCTION__, '3.0' );
-       return '';
-}
-
 /**
  * Checks that the taxonomy name exists.
  *
 /**
  * Checks that the taxonomy name exists.
  *
@@ -2547,3 +2561,44 @@ function is_term( $term, $taxonomy = '', $parent = 0 ) {
        _deprecated_function( __FUNCTION__, '3.0', 'term_exists()' );
        return term_exists( $term, $taxonomy, $parent );
 }
        _deprecated_function( __FUNCTION__, '3.0', 'term_exists()' );
        return term_exists( $term, $taxonomy, $parent );
 }
+
+/**
+ * Is the current admin page generated by a plugin?
+ *
+ * @since 1.5.0
+ * @deprecated 3.1
+ * @deprecated Use global $plugin_page and/or get_plugin_page_hookname() hooks.
+ *
+ * @global $plugin_page
+ *
+ * @return bool
+ */
+function is_plugin_page() {
+       _deprecated_function( __FUNCTION__, '3.1'  );
+
+       global $plugin_page;
+
+       if ( isset($plugin_page) )
+               return true;
+
+       return false;
+}
+
+/**
+ * Update the categories cache.
+ *
+ * This function does not appear to be used anymore or does not appear to be
+ * needed. It might be a legacy function left over from when there was a need
+ * for updating the category cache.
+ *
+ * @since 1.5.0
+ * @deprecated 3.1
+ *
+ * @return bool Always return True
+ */
+function update_category_cache() {
+       _deprecated_function( __FUNCTION__, '3.1'  );
+
+       return true;
+}
+