diff --git a/wp-admin/admin.php b/wp-admin/admin.php index 63a31a138d..1ccf107d53 100644 --- a/wp-admin/admin.php +++ b/wp-admin/admin.php @@ -215,13 +215,13 @@ if ( isset($plugin_page) ) { exit(); } else { do_action("load-$pagenow"); - // Backwards compatibility with old load-page-new.php, load-page.php, - // and load-categories.php actions. - if ( $typenow == 'page' ) { - if ( $pagenow == 'post-new.php' ) - do_action( 'load-page-new.php' ); - elseif ( $pagenow == 'post.php' ) - do_action( 'load-page.php' ); + // Backwards compatibility with old load-page-new.php, load-page.php, + // and load-categories.php actions. + if ( $typenow == 'page' ) { + if ( $pagenow == 'post-new.php' ) + do_action( 'load-page-new.php' ); + elseif ( $pagenow == 'post.php' ) + do_action( 'load-page.php' ); } elseif ( $taxnow == 'category' && $pagenow == 'edit-tags.php' ) { do_action( 'load-categories.php' ); } diff --git a/wp-admin/css/nav-menu.dev.css b/wp-admin/css/nav-menu.dev.css index b1d08366d3..601b8bf53e 100644 --- a/wp-admin/css/nav-menu.dev.css +++ b/wp-admin/css/nav-menu.dev.css @@ -95,7 +95,7 @@ body { #menu-management .menu-add-new abbr { font-weight:bold; } - + #nav-menu-footer { border-width: 0 1px 1px 1px; -moz-border-radius-bottomleft: 6px; diff --git a/wp-admin/custom-header.php b/wp-admin/custom-header.php index 5cab9b0742..c085d6fc41 100644 --- a/wp-admin/custom-header.php +++ b/wp-admin/custom-header.php @@ -558,8 +558,8 @@ class Custom_Image_Header { @@ -644,7 +644,7 @@ wp_nonce_field( 'custom-header-options', '_wpnonce-custom-header-options' ); ?> - +

diff --git a/wp-admin/includes/bookmark.php b/wp-admin/includes/bookmark.php index 6b5aab7840..0ed560c191 100644 --- a/wp-admin/includes/bookmark.php +++ b/wp-admin/includes/bookmark.php @@ -120,7 +120,7 @@ function get_link_to_edit( $link_id ) { } /** - * This function inserts/updates links into/in the database. + * This function inserts/updates links into/in the database. * * @since 2.0.0 * @@ -221,7 +221,7 @@ function wp_insert_link( $linkdata, $wp_error = false ) { * @since 2.1.0 * * @param int $link_id ID of link to update - * @param array $link_categories Array of categories to + * @param array $link_categories Array of categories to */ function wp_set_link_cats( $link_id = 0, $link_categories = array() ) { // If $link_categories isn't already an array, make it one: diff --git a/wp-admin/includes/default-list-tables.php b/wp-admin/includes/default-list-tables.php index cc29bc226f..569e793bb8 100644 --- a/wp-admin/includes/default-list-tables.php +++ b/wp-admin/includes/default-list-tables.php @@ -85,7 +85,7 @@ class WP_Posts_Table extends WP_List_Table { $total_items = $this->hierarchical_display ? $wp_query->post_count : $wp_query->found_posts; $per_page = $this->get_items_per_page( 'edit_' . $post_type . '_per_page' ); - $per_page = apply_filters( 'edit_posts_per_page', $per_page, $post_type ); + $per_page = apply_filters( 'edit_posts_per_page', $per_page, $post_type ); if ( $this->hierarchical_display ) $total_pages = ceil( $total_items / $per_page ); @@ -161,7 +161,7 @@ class WP_Posts_Table extends WP_List_Table { $status_links[$status_name] = "
  • " . sprintf( _n( $status->label_count[0], $status->label_count[1], $num_posts->$status_name ), number_format_i18n( $num_posts->$status_name ) ) . ''; } - + return $status_links; } @@ -735,11 +735,11 @@ class WP_Posts_Table extends WP_List_Table { $authors_dropdown = ''; if ( is_super_admin() || current_user_can( $post_type_object->cap->edit_others_posts ) ) : - $users_opt = array( - 'name' => 'post_author', - 'class'=> 'authors', - 'multi' => 1, - 'echo' => 0 + $users_opt = array( + 'name' => 'post_author', + 'class'=> 'authors', + 'multi' => 1, + 'echo' => 0 ); if ( $bulk ) $users_opt['show_option_none'] = __( '— No Change —' ); @@ -998,7 +998,7 @@ class WP_Media_Table extends WP_List_Table { function check_permissions() { if ( !current_user_can('upload_files') ) wp_die( __( 'You do not have permission to upload files.' ) ); - } + } function prepare_items() { global $lost, $wpdb, $wp_query, $post_mime_types, $avail_post_mime_types; @@ -1488,10 +1488,10 @@ class WP_Terms_Table extends WP_List_Table { $args['order'] = trim( stripslashes( $_REQUEST['order'] ) ); $this->callback_args = $args; - + $this->set_pagination_args( array( 'total_items' => wp_count_terms( $taxonomy, compact( 'search' ) ), - 'per_page' => $tags_per_page, + 'per_page' => $tags_per_page, ) ); } @@ -1677,7 +1677,7 @@ class WP_Terms_Table extends WP_List_Table { return $out; } - + function column_description( $tag ) { return $tag->description; } @@ -1711,7 +1711,7 @@ class WP_Terms_Table extends WP_List_Table { function column_default( $tag, $column_name ) { global $taxonomy; - + return apply_filters( "manage_${taxonomy}_custom_column", '', $column_name, $tag->term_id ); $out .= ""; } @@ -1820,10 +1820,10 @@ class WP_Users_Table extends WP_List_Table { $wp_user_search = new WP_User_Query( $args ); $this->items = $wp_user_search->get_results(); - + $this->set_pagination_args( array( 'total_items' => $wp_user_search->get_total(), - 'per_page' => $users_per_page, + 'per_page' => $users_per_page, ) ); } @@ -1888,7 +1888,7 @@ class WP_Users_Table extends WP_List_Table { items = get_bookmarks( $args ); - } + } function no_items() { _e( 'No links found.' ); @@ -2724,7 +2724,7 @@ class WP_Sites_Table extends WP_List_Table { ) ); } - function check_permissions() { + function check_permissions() { if ( ! current_user_can( 'manage_sites' ) ) wp_die( __( 'You do not have permission to access this page.' ) ); } @@ -3014,7 +3014,7 @@ class WP_MS_Users_Table extends WP_List_Table { function check_permissions() { if ( !is_multisite() ) wp_die( __( 'Multisite support is not enabled.' ) ); - + if ( ! current_user_can( 'manage_network_users' ) ) wp_die( __( 'You do not have permission to access this page.' ) ); } @@ -3045,10 +3045,10 @@ class WP_MS_Users_Table extends WP_List_Table { $wp_user_search = new WP_User_Query( $args ); $this->items = $wp_user_search->get_results(); - + $this->set_pagination_args( array( 'total_items' => $wp_user_search->get_total(), - 'per_page' => $users_per_page, + 'per_page' => $users_per_page, ) ); } @@ -3367,7 +3367,7 @@ class WP_Plugins_Table extends WP_List_Table { } uasort( $this->items, '_order_plugins_callback' ); } - + $plugins_per_page = $this->get_items_per_page( 'plugins_per_page', 999 ); $start = ( $page - 1 ) * $plugins_per_page; @@ -3416,7 +3416,7 @@ class WP_Plugins_Table extends WP_List_Table { function get_views() { global $totals, $status; - + $status_links = array(); foreach ( $totals as $type => $count ) { if ( !$count ) @@ -3452,7 +3452,7 @@ class WP_Plugins_Table extends WP_List_Table { break; } - $status_links[$type] = sprintf( "
  • %s", + $status_links[$type] = sprintf( "
  • %s", add_query_arg('plugin_status', $type, 'plugins.php'), ( $type == $status ) ? ' class="current"' : '', sprintf( $text, number_format_i18n( $count ) ) @@ -3640,7 +3640,7 @@ class WP_Plugin_Install_Table extends WP_List_Table { function check_permissions() { if ( ! current_user_can('install_plugins') ) - wp_die(__('You do not have sufficient permissions to install plugins on this site.')); + wp_die(__('You do not have sufficient permissions to install plugins on this site.')); } function prepare_items() { @@ -4081,8 +4081,8 @@ class WP_Theme_Install_Table extends WP_List_Table { function prepare_items() { include( ABSPATH . 'wp-admin/includes/theme-install.php' ); - global $tabs, $tab, $paged, $type, $term, $theme_field_defaults; - + global $tabs, $tab, $paged, $type, $term, $theme_field_defaults; + wp_reset_vars( array( 'tab' ) ); $paged = $this->get_pagenum(); diff --git a/wp-admin/includes/list-table.php b/wp-admin/includes/list-table.php index bd0f2c8982..9605f551d3 100644 --- a/wp-admin/includes/list-table.php +++ b/wp-admin/includes/list-table.php @@ -261,7 +261,7 @@ class WP_List_Table { if ( isset( $_REQUEST['action2'] ) && -1 != $_REQUEST['action2'] ) return $_REQUEST['action2']; - + return false; } @@ -398,7 +398,7 @@ class WP_List_Table { */ function get_pagenum( $query_var = 'paged' ) { $pagenum = isset( $_REQUEST[$query_var] ) ? absint( $_REQUEST[$query_var] ) : 0; - + return max( 1, $pagenum ); } @@ -409,7 +409,7 @@ class WP_List_Table { * @access protected * * @return int - */ + */ function get_items_per_page( $option, $default = 20 ) { $per_page = (int) get_user_option( $option ); if ( empty( $per_page ) || $per_page < 1 ) @@ -621,7 +621,7 @@ class WP_List_Table { * @access protected * * @return array - */ + */ function get_table_classes() { extract( $this->_args ); diff --git a/wp-admin/includes/meta-boxes.php b/wp-admin/includes/meta-boxes.php index c84ff754cf..24507446b7 100644 --- a/wp-admin/includes/meta-boxes.php +++ b/wp-admin/includes/meta-boxes.php @@ -508,8 +508,8 @@ function post_author_meta_box($post) { ?> 'post_author_override', + wp_dropdown_users( array( + 'name' => 'post_author_override', 'selected' => empty($post->ID) ? $user_ID : $post->post_author ) ); } diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php index 12781fbd5a..90868dbbef 100644 --- a/wp-admin/includes/template.php +++ b/wp-admin/includes/template.php @@ -2072,7 +2072,7 @@ function set_current_screen( $id = '' ) { $current_screen->is_network = is_network_admin() ? true : false; $current_screen->is_user = is_user_admin() ? true : false; - + if ( $current_screen->is_network ) { $current_screen->base .= '-network'; $current_screen->id .= '-network'; diff --git a/wp-admin/js/list-table.dev.js b/wp-admin/js/list-table.dev.js index 49609b07ba..3b44620e9a 100644 --- a/wp-admin/js/list-table.dev.js +++ b/wp-admin/js/list-table.dev.js @@ -77,7 +77,7 @@ window.listTable = { this._callback = callback; this.fetch_list( - data, + data, $.proxy(this, 'handle_success'), $.proxy(this, 'handle_error') ); diff --git a/wp-admin/js/nav-menu.dev.js b/wp-admin/js/nav-menu.dev.js index 48c6516608..d58d6b2735 100644 --- a/wp-admin/js/nav-menu.dev.js +++ b/wp-admin/js/nav-menu.dev.js @@ -918,7 +918,7 @@ var wpNavMenu; takenIDs[newID] = true; if ( newID != matched[1] ) { $item.html( $item.html().replace(new RegExp( - 'menu-item\\[' + matched[1] + '\\]', 'g'), + 'menu-item\\[' + matched[1] + '\\]', 'g'), 'menu-item[' + newID + ']' ) ); } diff --git a/wp-admin/js/theme.dev.js b/wp-admin/js/theme.dev.js index 80e07e4b4a..f994f3195b 100644 --- a/wp-admin/js/theme.dev.js +++ b/wp-admin/js/theme.dev.js @@ -47,7 +47,7 @@ var ThemeViewer; // Set the options opts.search = $( 'input[name=s]' ).val(); opts.order = document.location.href.match( /order=(\w*)/ ) ? document.location.href.match( /order=(\w*)/ )[1] : 'random'; - + $( '#availablethemes td' ).fadeTo( 500, 0.1, function() { $( '#availablethemes td img' ).hide(); } ); @@ -55,7 +55,7 @@ var ThemeViewer; return false; }); } - + // These are the functions we expose var api = { init: init @@ -68,4 +68,4 @@ var ThemeViewer; jQuery( document ).ready( function($) { theme_viewer = new ThemeViewer(); theme_viewer.init(); -}); \ No newline at end of file +}); \ No newline at end of file diff --git a/wp-admin/network/edit.php b/wp-admin/network/edit.php index e5913da816..6afc631439 100644 --- a/wp-admin/network/edit.php +++ b/wp-admin/network/edit.php @@ -74,7 +74,7 @@ function confirm_delete_users( $users ) { } } } - + submit_button( __('Confirm Deletion'), 'delete' ); ?> diff --git a/wp-admin/options-general.php b/wp-admin/options-general.php index edd6ed32e8..24af5f22c9 100644 --- a/wp-admin/options-general.php +++ b/wp-admin/options-general.php @@ -49,7 +49,7 @@ function add_js() { $.post(ajaxurl, { action: 'date_format_custom' == format.attr('name') ? 'date_format' : 'time_format', date : format.val(), - }, function(d) { format.siblings('img').css('visibility','hidden'); format.siblings('.example').text(d); } ); + }, function(d) { format.siblings('img').css('visibility','hidden'); format.siblings('.example').text(d); } ); }); }); //]]> diff --git a/wp-admin/themes.php b/wp-admin/themes.php index 5d31a4a1e0..ffcf2662d4 100644 --- a/wp-admin/themes.php +++ b/wp-admin/themes.php @@ -110,7 +110,7 @@ require_once('./admin-header.php'); } } echo implode ( ' | ', $options ); - + if ( $ct->tags ) : ?>

    tags); ?>

    @@ -146,7 +146,7 @@ if ( ! current_user_can( 'switch_themes' ) ) { $features ) : $feature_name = esc_html( $feature_name ); ?> - +
    diff --git a/wp-includes/canonical.php b/wp-includes/canonical.php index 81af9be623..738ae70715 100644 --- a/wp-includes/canonical.php +++ b/wp-includes/canonical.php @@ -342,13 +342,13 @@ function redirect_canonical($requested_url=null, $do_redirect=true) { if ( !$redirect_url || $redirect_url == $requested_url ) return false; - - // Hex encoded octets are case-insensitive. + + // Hex encoded octets are case-insensitive. if ( false !== strpos($requested_url, '%') ) { if ( !function_exists('lowercase_octets') ) { - function lowercase_octets($matches) { - return strtolower( $matches[0] ); - } + function lowercase_octets($matches) { + return strtolower( $matches[0] ); + } } $requested_url = preg_replace_callback('|%[a-fA-F0-9][a-fA-F0-9]|', 'lowercase_octets', $requested_url); } diff --git a/wp-includes/category-template.php b/wp-includes/category-template.php index 608c4d281b..a53a83c31b 100644 --- a/wp-includes/category-template.php +++ b/wp-includes/category-template.php @@ -963,7 +963,7 @@ function has_tag( $tag = '', $post = null ) { /** * Check if the current post has any of given terms. - * + * * The given terms are checked against the post's terms' term_ids, names and slugs. * Terms given as integers will only be checked against the post's terms' term_ids. * If no terms are given, determines if post has any terms. diff --git a/wp-includes/comment.php b/wp-includes/comment.php index aa1655eabd..9ff0233952 100644 --- a/wp-includes/comment.php +++ b/wp-includes/comment.php @@ -311,7 +311,7 @@ class WP_Comment_Query extends WP_Object_Query { wp_cache_add( $cache_key, $comments, 'comment' ); - return $comments; + return $comments; } } diff --git a/wp-includes/functions.php b/wp-includes/functions.php index 931f8de30a..eea86d7225 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -4342,7 +4342,7 @@ function _wp_mysql_week( $column ) { * Finds hierarchy loops using a callback function that maps objects to parents. * * @since 3.1.0 - * @access private + * @access private * * @param callback $callback function that accepts ( ID, callback_arg, ... ) and outputs parent_ID * @param $start The ID to start the loop check at diff --git a/wp-includes/general-template.php b/wp-includes/general-template.php index e9412eacb7..a20c6d511b 100644 --- a/wp-includes/general-template.php +++ b/wp-includes/general-template.php @@ -654,7 +654,7 @@ function post_type_archive_title() { if ( ! is_post_type_archive() ) return; - + $post_type_obj = get_post_type_object( get_query_var( 'post_type' ) ); $title = apply_filters('post_type_archive_title', $post_type_obj->labels->name ); @@ -663,7 +663,7 @@ function post_type_archive_title() { else return $title; } - + /** * Display or retrieve page title for category archive. * diff --git a/wp-includes/link-template.php b/wp-includes/link-template.php index 5869c9954a..51e9135bab 100644 --- a/wp-includes/link-template.php +++ b/wp-includes/link-template.php @@ -858,9 +858,9 @@ function get_post_type_archive_link( $post_type ) { * @since 3.1.0 * * @param string $post_type Post type - * @param string $feed Optional. Feed type + * @param string $feed Optional. Feed type * @return string - */ + */ function get_post_type_archive_feed_link( $post_type, $feed = '' ) { $default_feed = get_default_feed(); if ( empty( $feed ) ) diff --git a/wp-includes/ms-blogs.php b/wp-includes/ms-blogs.php index c3f16fd562..1a9c4521ce 100644 --- a/wp-includes/ms-blogs.php +++ b/wp-includes/ms-blogs.php @@ -116,7 +116,7 @@ function get_id_from_blogname( $name ) { * Retrieve the details for a blog from the blogs table and blog options. * * @since MU - * + * * @param int|string|array $fields A blog ID, a blog name, or an array of fields to query against. * @param bool $get_all Whether to retrieve all details or only the details in the blogs table. Default is true. * @return object Blog details. @@ -488,9 +488,9 @@ function switch_to_blog( $new_blog, $validate = false ) { $wp_roles->__construct(); $wpdb->suppress_errors( false ); } - + if ( did_action('init') ) { - $current_user = wp_get_current_user(); + $current_user = wp_get_current_user(); if ( is_object( $current_user ) ) $current_user->for_blog( $blog_id ); } @@ -663,7 +663,7 @@ function get_blog_status( $id, $pref ) { * Get a list of most recently updated blogs. * * @since MU - * + * * @param $deprecated Not used * @param int $start The offset * @param int $quantity The maximum number of blogs to retrieve. Default is 40. diff --git a/wp-includes/ms-functions.php b/wp-includes/ms-functions.php index b3ada31139..ddc8d2bf24 100644 --- a/wp-includes/ms-functions.php +++ b/wp-includes/ms-functions.php @@ -124,7 +124,7 @@ function get_active_blog_for_user( $user_id ) { * * @since MU 1.1 * @uses get_blogs_of_user() - * + * * @param int $user_id The unique ID of the user * @param int $blog Optional. If no blog_id is provided, current site is used * @return bool @@ -268,7 +268,7 @@ function add_user_to_blog( $blog_id, $user_id, $role ) { * Use the 'remove_user_from_blog' action to fire an event when * users are removed from a blog. * - * Accepts an optional $reassign parameter, if you want to + * Accepts an optional $reassign parameter, if you want to * reassign the user's blog posts to another user upon removal. * * @since MU 1.0 diff --git a/wp-includes/nav-menu-template.php b/wp-includes/nav-menu-template.php index 67d535317c..2c57d086d6 100644 --- a/wp-includes/nav-menu-template.php +++ b/wp-includes/nav-menu-template.php @@ -196,7 +196,7 @@ function wp_nav_menu( $args = array() ) { $sorted_menu_items[$menu_item->menu_order] = $menu_item; unset($menu_items); - + $sorted_menu_items = apply_filters( 'wp_nav_menu_objects', $sorted_menu_items, $args ); $items .= walk_nav_menu_tree( $sorted_menu_items, $args->depth, $args ); @@ -314,9 +314,9 @@ function _wp_menu_item_classes_by_context( &$menu_items ) { $possible_object_parents = array_filter( $possible_object_parents ); foreach ( (array) $menu_items as $key => $menu_item ) { - + $menu_items[$key]->current = false; - + $classes = (array) $menu_item->classes; $classes[] = 'menu-item'; $classes[] = 'menu-item-type-' . $menu_item->type; @@ -362,7 +362,7 @@ function _wp_menu_item_classes_by_context( &$menu_items ) { $current_url = untrailingslashit( ( is_ssl() ? 'https://' : 'http://' ) . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'] ); $item_url = untrailingslashit( strpos( $menu_item->url, '#' ) ? substr( $menu_item->url, 0, strpos( $menu_item->url, '#' ) ) : $menu_item->url ); $_indexless_current = untrailingslashit( preg_replace( '/index.php$/', '', $current_url ) ); - + if ( in_array( $item_url, array( $current_url, $_indexless_current ) ) ) { $classes[] = 'current-menu-item'; $menu_items[$key]->current = true; @@ -383,7 +383,7 @@ function _wp_menu_item_classes_by_context( &$menu_items ) { $active_parent_object_ids[] = (int) $menu_item->post_parent; $active_object = $menu_item->object; } - + if ( untrailingslashit($item_url) == home_url() ) $classes[] = 'menu-item-home'; } @@ -403,7 +403,7 @@ function _wp_menu_item_classes_by_context( &$menu_items ) { $classes = (array) $parent_item->classes; $menu_items[$key]->current_item_ancestor = false; $menu_items[$key]->current_item_parent = false; - + if ( isset( $parent_item->type ) && ( diff --git a/wp-includes/post.php b/wp-includes/post.php index 20f81e176a..a05a6c918e 100644 --- a/wp-includes/post.php +++ b/wp-includes/post.php @@ -496,7 +496,7 @@ function get_post_format( $post ) { * * @since 3.1.0 * @uses has_term() - * + * * @param string $format The format to check for * @param object|id $post The post to check. If not supplied, defaults to the current post if used in the loop. * @return bool True if the post has the format, false otherwise. @@ -3812,7 +3812,7 @@ function wp_mime_type_icon( $mime = 0 ) { /** * Checked for changed slugs for published post objects and save the old slug. * - * The function is used when a post object of any type is updated, + * The function is used when a post object of any type is updated, * by comparing the current and previous post objects. * * If the slug was changed and not already part of the old slugs then it will be diff --git a/wp-includes/query.php b/wp-includes/query.php index e2e2cba6d9..c4f428fb90 100644 --- a/wp-includes/query.php +++ b/wp-includes/query.php @@ -103,7 +103,7 @@ function wp_reset_postdata() { * Month, Year, Category, Author, ... * * If the $post_types parameter is specified, this function will additionally - * check if the query is for exactly one of the post types specified. If a plugin + * check if the query is for exactly one of the post types specified. If a plugin * is causing multiple post types to appear in the query, specifying a post type * will cause this check to return false. * @@ -135,7 +135,7 @@ function is_post_type_archive( $post_types = '' ) { return $wp_query->is_post_type_archive( $post_types ); } - + /** * Is the query for an attachment page? * @@ -2648,7 +2648,7 @@ class WP_Query extends WP_Object_Query { * Month, Year, Category, Author, ... * * If the $post_types parameter is specified, this function will additionally - * check if the query is for exactly one of the post types specified. If a plugin + * check if the query is for exactly one of the post types specified. If a plugin * is causing multiple post types to appear in the query, specifying a post type * will cause this check to return false. * diff --git a/wp-includes/taxonomy.php b/wp-includes/taxonomy.php index 608df1b190..537090a887 100644 --- a/wp-includes/taxonomy.php +++ b/wp-includes/taxonomy.php @@ -503,7 +503,7 @@ function get_objects_in_term( $terms, $taxonomies, $args = array() ) { if ( $term = get_term_by( $field, $term, $taxonomy ) ) $term = $term->term_id; else - continue; + continue; } $children = array_merge( $children, get_term_children( $term, $taxonomy ) ); $children[] = $term; @@ -1446,13 +1446,13 @@ function wp_delete_term( $term, $taxonomy, $args = array() ) { $tt_id = $ids['term_taxonomy_id']; $defaults = array(); - + if ( 'category' == $taxonomy ) { $defaults['default'] = get_option( 'default_category' ); if ( $defaults['default'] == $term ) return 0; // Don't delete the default category } - + $args = wp_parse_args($args, $defaults); extract($args, EXTR_SKIP); @@ -2641,7 +2641,7 @@ function get_term_link( $term, $taxonomy = '') { $termlink = home_url( user_trailingslashit($termlink, 'category') ); } // Back Compat filters. - if ( 'post_tag' == $taxonomy ) + if ( 'post_tag' == $taxonomy ) $termlink = apply_filters( 'tag_link', $termlink, $term->term_id ); elseif ( 'category' == $taxonomy ) $termlink = apply_filters( 'category_link', $termlink, $term->term_id ); @@ -2815,7 +2815,7 @@ function is_object_in_taxonomy($object_type, $taxonomy) { return false; } - + /** * Get an array of ancestor IDs for a given object. * @@ -2825,13 +2825,13 @@ function is_object_in_taxonomy($object_type, $taxonomy) { */ function get_ancestors($object_id = 0, $object_type = '') { $object_id = (int) $object_id; - + $ancestors = array(); if ( empty( $object_id ) ) { return apply_filters('get_ancestors', $ancestors, $object_id, $object_type); } - + if ( is_taxonomy_hierarchical( $object_type ) ) { $term = get_term($object_id, $object_type); while ( ! is_wp_error($term) && ! empty( $term->parent ) && ! in_array( $term->parent, $ancestors ) ) { @@ -2840,7 +2840,7 @@ function get_ancestors($object_id = 0, $object_type = '') { } } elseif ( null !== get_post_type_object( $object_type ) ) { $object = get_post($object_id); - if ( ! is_wp_error( $object ) && isset( $object->ancestors ) && is_array( $object->ancestors ) ) + if ( ! is_wp_error( $object ) && isset( $object->ancestors ) && is_array( $object->ancestors ) ) $ancestors = $object->ancestors; else { while ( ! is_wp_error($object) && ! empty( $object->post_parent ) && ! in_array( $object->post_parent, $ancestors ) ) { diff --git a/wp-includes/theme-compat/comments-popup.php b/wp-includes/theme-compat/comments-popup.php index 479bbeb7f4..86582ba37a 100644 --- a/wp-includes/theme-compat/comments-popup.php +++ b/wp-includes/theme-compat/comments-popup.php @@ -3,9 +3,9 @@ * @package WordPress * @subpackage Theme_Compat * @deprecated 3.0 - * + * * This file is here for Backwards compatibility with old themes and will be removed in a future version - * + * */ _deprecated_file( sprintf( __( 'Theme without %1$s' ), basename(__FILE__) ), '3.0', null, sprintf( __('Please include a %1$s template in your theme.'), basename(__FILE__) ) ); ?> diff --git a/wp-includes/theme-compat/comments.php b/wp-includes/theme-compat/comments.php index b095d51c75..c6fbb7fcd4 100644 --- a/wp-includes/theme-compat/comments.php +++ b/wp-includes/theme-compat/comments.php @@ -3,18 +3,18 @@ * @package WordPress * @subpackage Theme_Compat * @deprecated 3.0 - * + * * This file is here for Backwards compatibility with old themes and will be removed in a future version - * + * */ _deprecated_file( sprintf( __( 'Theme without %1$s' ), basename(__FILE__) ), '3.0', null, sprintf( __('Please include a %1$s template in your theme.'), basename(__FILE__) ) ); // Do not delete these lines if (!empty($_SERVER['SCRIPT_FILENAME']) && 'comments.php' == basename($_SERVER['SCRIPT_FILENAME'])) die ('Please do not load this page directly. Thanks!'); - + if ( post_password_required() ) { ?> -

    +

    -
    +
    -
    +

    logged in to post a comment.'), wp_login_url( get_permalink() )); ?>

    @@ -90,7 +90,7 @@ _deprecated_file( sprintf( __( 'Theme without %1$s' ), basename(__FILE__) ), '3.

    - +

    ID); ?> diff --git a/wp-includes/theme-compat/footer.php b/wp-includes/theme-compat/footer.php index 93e44ccb22..0e987edef4 100644 --- a/wp-includes/theme-compat/footer.php +++ b/wp-includes/theme-compat/footer.php @@ -3,9 +3,9 @@ * @package WordPress * @subpackage Theme_Compat * @deprecated 3.0 - * + * * This file is here for Backwards compatibility with old themes and will be removed in a future version - * + * */ _deprecated_file( sprintf( __( 'Theme without %1$s' ), basename(__FILE__) ), '3.0', null, sprintf( __('Please include a %1$s template in your theme.'), basename(__FILE__) ) ); ?> diff --git a/wp-includes/theme-compat/header.php b/wp-includes/theme-compat/header.php index 6089b18110..7abaa02ff2 100644 --- a/wp-includes/theme-compat/header.php +++ b/wp-includes/theme-compat/header.php @@ -3,9 +3,9 @@ * @package WordPress * @subpackage Theme_Compat * @deprecated 3.0 - * + * * This file is here for Backwards compatibility with old themes and will be removed in a future version - * + * */ _deprecated_file( sprintf( __( 'Theme without %1$s' ), basename(__FILE__) ), '3.0', null, sprintf( __('Please include a %1$s template in your theme.'), basename(__FILE__) ) ); ?> diff --git a/wp-includes/theme-compat/sidebar.php b/wp-includes/theme-compat/sidebar.php index d2c97277a5..9c8cf5b297 100644 --- a/wp-includes/theme-compat/sidebar.php +++ b/wp-includes/theme-compat/sidebar.php @@ -3,9 +3,9 @@ * @package WordPress * @subpackage Theme_Compat * @deprecated 3.0 - * + * * This file is here for Backwards compatibility with old themes and will be removed in a future version - * + * */ _deprecated_file( sprintf( __( 'Theme without %1$s' ), basename(__FILE__) ), '3.0', null, sprintf( __('Please include a %1$s template in your theme.'), basename(__FILE__) ) ); ?> diff --git a/wp-includes/user.php b/wp-includes/user.php index 00313beae5..c5fe577e48 100644 --- a/wp-includes/user.php +++ b/wp-includes/user.php @@ -642,7 +642,7 @@ function get_ordered_blogs_of_user( $user_id, $visibility = true ) { $blogs = get_blogs_of_user( $user_id ); $order_meta = get_user_meta( $user_id, 'blog_order' ); $visible_meta = get_user_meta( $user_id, 'blog_visibility' ); - + $order = $order_meta; if ( !is_array( $order ) ) $order = array(); @@ -650,7 +650,7 @@ function get_ordered_blogs_of_user( $user_id, $visibility = true ) { $visible = $visible_meta; if ( !is_array( $visible ) ) $visible = array(); - + // Index the blogs by userblog_id and set the visibility flag // Visibility is on by default, unless a linked site then off foreach ( $blogs as $blog ) { @@ -667,7 +667,7 @@ function get_ordered_blogs_of_user( $user_id, $visibility = true ) { // A previous change was saving the entire blog details into ordered, not just the blog ID - this detects it if ( is_object( $id ) && isset( $id->userblog_id ) ) $id = $id->userblog_id; - + if ( is_numeric( $id ) && isset( $newblogs[intval( $id )] ) ) { $ordered[$id] = $newblogs[$id]; unset( $newblogs[$id] ); @@ -724,7 +724,7 @@ function set_blog_visibility( $blog_id, $visible ) { */ function is_blog_user( $blog_id = 0 ) { global $wpdb; - + $current_user = wp_get_current_user(); if ( !$blog_id ) $blog_id = $wpdb->blogid; diff --git a/wp-includes/wp-db.php b/wp-includes/wp-db.php index cd01e7097d..f35d6eb996 100644 --- a/wp-includes/wp-db.php +++ b/wp-includes/wp-db.php @@ -540,7 +540,7 @@ class wpdb { /** * Sets the connection's character set. - * + * * @param resource $dbh The resource given by mysql_connect * @param string $charset The character set (optional) * @param string $collate The collation (optional) @@ -740,7 +740,7 @@ class wpdb { * @return null Always null. */ function select( $db, $dbh = null) { - if ( is_null($dbh) ) + if ( is_null($dbh) ) $dbh = $this->dbh; if ( !@mysql_select_db( $db, $dbh ) ) { @@ -1043,7 +1043,7 @@ class wpdb {

    If you're unsure what these terms mean you should probably contact your host. If you still need help you can always visit the WordPress Support Forums.

    "/*/WP_I18N_DB_CONN_ERROR*/, $this->dbhost ), 'db_connect_fail' ); - + //If show errors is disabled then we need to die anyway as we don't have a working DB connection die(); } diff --git a/wp-login.php b/wp-login.php index 270c510a87..f0ed858cc1 100644 --- a/wp-login.php +++ b/wp-login.php @@ -261,7 +261,7 @@ function check_password_reset_key($key, $login) { if ( empty( $user ) ) return new WP_Error('invalid_key', __('Invalid key')); - + return $user; }