WordPress.org

Make WordPress Core

Ticket #22665: 22665.2.diff

File 22665.2.diff, 19.3 KB (added by trepmal, 5 years ago)

missed one

  • wp-includes/class-http.php

     
    134134                unset( $homeURL );
    135135
    136136                // If we are streaming to a file but no filename was given drop it in the WP temp dir
    137                 // and pick it's name using the basename of the $url
     137                // and pick its name using the basename of the $url
    138138                if ( $r['stream']  && empty( $r['filename'] ) )
    139139                        $r['filename'] = get_temp_dir() . basename( $url );
    140140
     
    530530                if ( !empty($wildcard_regex) )
    531531                        return !preg_match($wildcard_regex, $check['host']);
    532532                else
    533                         return !in_array( $check['host'], $accessible_hosts ); //Inverse logic, If its in the array, then we can't access it.
     533                        return !in_array( $check['host'], $accessible_hosts ); //Inverse logic, If it's in the array, then we can't access it.
    534534
    535535        }
    536536
     
    555555                // Start off with the Absolute URL path
    556556                $path = ! empty( $url_parts['path'] ) ? $url_parts['path'] : '/';
    557557
    558                 // If the it's a root-relative path, then great
     558                // If it's a root-relative path, then great
    559559                if ( ! empty( $relative_url_parts['path'] ) && '/' == $relative_url_parts['path'][0] ) {
    560560                        $path = $relative_url_parts['path'];
    561561
  • wp-includes/js/tinymce/plugins/wplink/editor_plugin_src.js

     
    22        tinymce.create('tinymce.plugins.wpLink', {
    33                /**
    44                 * Initializes the plugin, this will be executed after the plugin has been created.
    5                  * This call is done before the editor instance has finished it's initialization so use the onInit event
     5                 * This call is done before the editor instance has finished its initialization so use the onInit event
    66                 * of the editor instance to intercept that event.
    77                 *
    88                 * @param {tinymce.Editor} ed Editor instance that the plugin is initialized in.
  • wp-includes/js/tinymce/plugins/wpdialogs/js/popup.js

     
    155155
    156156        /**
    157157         * Stores the current editor selection for later restoration. This can be useful since some browsers
    158          * looses it's selection if a control element is selected/focused inside the dialogs.
     158         * loses its selection if a control element is selected/focused inside the dialogs.
    159159         *
    160160         * @method storeSelection
    161161         */
     
    165165
    166166        /**
    167167         * Restores any stored selection. This can be useful since some browsers
    168          * looses it's selection if a control element is selected/focused inside the dialogs.
     168         * loses its selection if a control element is selected/focused inside the dialogs.
    169169         *
    170170         * @method restoreSelection
    171171         */
  • wp-includes/js/crop/cropper.css

     
    55        cursor: crosshair;
    66}
    77
    8 /* an extra classname is applied for Opera < 9.0 to fix it's lack of opacity support */
     8/* an extra classname is applied for Opera < 9.0 to fix its lack of opacity support */
    99.imgCrop_wrap.opera8 .imgCrop_overlay,
    1010.imgCrop_wrap.opera8 .imgCrop_clickArea {
    1111        background-color: transparent;
  • wp-includes/theme.php

     
    631631 */
    632632function preview_theme_ob_filter_callback( $matches ) {
    633633        if ( strpos($matches[4], 'onclick') !== false )
    634                 $matches[4] = preg_replace('#onclick=([\'"]).*?(?<!\\\)\\1#i', '', $matches[4]); //Strip out any onclicks from rest of <a>. (?<!\\\) means to ignore the '" if its escaped by \  to prevent breaking mid-attribute.
     634                $matches[4] = preg_replace('#onclick=([\'"]).*?(?<!\\\)\\1#i', '', $matches[4]); //Strip out any onclicks from rest of <a>. (?<!\\\) means to ignore the '" if it's escaped by \  to prevent breaking mid-attribute.
    635635        if (
    636636                ( false !== strpos($matches[3], '/wp-admin/') )
    637637        ||
  • wp-includes/comment.php

     
    16731673        if ( preg_match('#(image|audio|video|model)/#is', wp_remote_retrieve_header( $response, 'content-type' )) )
    16741674                return false;
    16751675
    1676         // Now do a GET since we're going to look in the html headers (and we're sure its not a binary file)
     1676        // Now do a GET since we're going to look in the html headers (and we're sure it's not a binary file)
    16771677        $response = wp_remote_get( $url, array( 'timeout' => 2, 'httpversion' => '1.0' ) );
    16781678
    16791679        if ( is_wp_error( $response ) )
  • wp-includes/ms-blogs.php

     
    8484}
    8585
    8686/**
    87  * Given a blog's (subdomain or directory) slug, retrieve it's id.
     87 * Given a blog's (subdomain or directory) slug, retrieve its id.
    8888 *
    8989 * @since MU
    9090 *
  • wp-includes/feed-atom-comments.php

     
    7575                <thr:in-reply-to ref="<?php the_guid(); ?>" href="<?php the_permalink_rss() ?>" type="<?php bloginfo_rss('html_type'); ?>" />
    7676<?php else : // This comment is in reply to another comment
    7777        $parent_comment = get_comment($comment->comment_parent);
    78         // The rel attribute below and the id tag above should be GUIDs, but WP doesn't create them for comments (unlike posts). Either way, its more important that they both use the same system
     78        // The rel attribute below and the id tag above should be GUIDs, but WP doesn't create them for comments (unlike posts). Either way, it's more important that they both use the same system
    7979?>
    8080                <thr:in-reply-to ref="<?php comment_guid($parent_comment) ?>" href="<?php echo get_comment_link($parent_comment) ?>" type="<?php bloginfo_rss('html_type'); ?>" />
    8181<?php endif;
  • wp-includes/query.php

     
    20792079                if ( $q['day'] )
    20802080                        $where .= " AND DAYOFMONTH($wpdb->posts.post_date)='" . $q['day'] . "'";
    20812081
    2082                 // If we've got a post_type AND its not "any" post_type.
     2082                // If we've got a post_type AND it's not "any" post_type.
    20832083                if ( !empty($q['post_type']) && 'any' != $q['post_type'] ) {
    20842084                        foreach ( (array)$q['post_type'] as $_post_type ) {
    20852085                                $ptype_obj = get_post_type_object($_post_type);
  • wp-includes/deprecated.php

     
    394394 * @param string $cat_name Optional. The category name to use. If no match is found uses all.
    395395 * @param string $before Optional. The html to output before the link.
    396396 * @param string $after Optional. The html to output after the link.
    397  * @param string $between Optional. The html to output between the link/image and it's description. Not used if no image or $show_images is true.
     397 * @param string $between Optional. The html to output between the link/image and its description. Not used if no image or $show_images is true.
    398398 * @param bool $show_images Optional. Whether to show images (if defined).
    399399 * @param string $orderby Optional. The order to output the links. E.g. 'id', 'name', 'url', 'description' or 'rating'. Or maybe owner.
    400400 *              If you start the name with an underscore the order will be reversed. You can also specify 'rand' as the order which will return links in a
     
    547547 * @param string $cat_name The category name to use. If no match is found uses all
    548548 * @param string $before The html to output before the link
    549549 * @param string $after The html to output after the link
    550  * @param string $between The html to output between the link/image and it's description. Not used if no image or show_images is true
     550 * @param string $between The html to output between the link/image and its description. Not used if no image or show_images is true
    551551 * @param bool $show_images Whether to show images (if defined).
    552552 * @param string $orderby the order to output the links. E.g. 'id', 'name', 'url',
    553553 *              'description', or 'rating'. Or maybe owner. If you start the name with an
     
    575575 * @param int $category The category to use. If no category supplied uses all
    576576 * @param string $before The html to output before the link
    577577 * @param string $after The html to output after the link
    578  * @param string $between The html to output between the link/image and it's description. Not used if no image or show_images == true
     578 * @param string $between The html to output between the link/image and its description. Not used if no image or show_images == true
    579579 * @param bool $show_images Whether to show images (if defined).
    580580 * @param string $orderby The order to output the links. E.g. 'id', 'name', 'url',
    581581 *              'description', or 'rating'. Or maybe owner. If you start the name with an
  • wp-includes/rss.php

     
    422422        else {
    423423                // Flow
    424424                // 1. check cache
    425                 // 2. if there is a hit, make sure its fresh
     425                // 2. if there is a hit, make sure it's fresh
    426426                // 3. if cached obj fails freshness check, fetch remote
    427427                // 4. if remote fails, return stale object, or error
    428428
  • wp-content/themes/twentyeleven/inc/widgets.php

     
    3030         *
    3131         * @param array An array of standard parameters for widgets in this theme
    3232         * @param array An array of settings for this widget instance
    33          * @return void Echoes it's output
     33         * @return void Echoes its output
    3434         **/
    3535        function widget( $args, $instance ) {
    3636                $cache = wp_cache_get( 'widget_twentyeleven_ephemera', 'widget' );
  • wp-admin/includes/plugin.php

     
    728728
    729729                $this_plugin_dir = trailingslashit( dirname($plugins_dir . $plugin_file) );
    730730                // If plugin is in its own directory, recursively delete the directory.
    731                 if ( strpos($plugin_file, '/') && $this_plugin_dir != $plugins_dir ) //base check on if plugin includes directory separator AND that its not the root plugin folder
     731                if ( strpos($plugin_file, '/') && $this_plugin_dir != $plugins_dir ) //base check on if plugin includes directory separator AND that it's not the root plugin folder
    732732                        $deleted = $wp_filesystem->delete($this_plugin_dir, true);
    733733                else
    734734                        $deleted = $wp_filesystem->delete($plugins_dir . $plugin_file);
  • wp-admin/includes/file.php

     
    926926                $credentials['connection_type'] = 'ftps';
    927927        else if ( !empty($_POST['connection_type']) )
    928928                $credentials['connection_type'] = stripslashes($_POST['connection_type']);
    929         else if ( !isset($credentials['connection_type']) ) //All else fails (And its not defaulted to something else saved), Default to FTP
     929        else if ( !isset($credentials['connection_type']) ) //All else fails (And it's not defaulted to something else saved), Default to FTP
    930930                $credentials['connection_type'] = 'ftp';
    931931
    932932        if ( ! $error &&
  • wp-admin/includes/class-wp-filesystem-base.php

     
    203203                                continue; //We want this to be caught by the next code block.
    204204
    205205                        //Working from /home/ to /user/ to /wordpress/ see if that file exists within the current folder,
    206                         // If its found, change into it and follow through looking for it.
     206                        // If it's found, change into it and follow through looking for it.
    207207                        // If it cant find WordPress down that route, it'll continue onto the next folder level, and see if that matches, and so on.
    208208                        // If it reaches the end, and still cant find it, it'll return false for the entire function.
    209209                        if ( isset($files[ $key ]) ){
  • wp-admin/includes/class-wp-users-list-table.php

     
    260260                        $actions = apply_filters( 'user_row_actions', $actions, $user_object );
    261261                        $edit .= $this->row_actions( $actions );
    262262
    263                         // Set up the checkbox ( because the user is editable, otherwise its empty )
     263                        // Set up the checkbox ( because the user is editable, otherwise it's empty )
    264264                        $checkbox = '<label class="screen-reader-text" for="cb-select-' . $user_object->ID . '">' . sprintf( __( 'Select %s' ), $user_object->user_login ) . '</label>'
    265265                                                . "<input type='checkbox' name='users[]' id='user_{$user_object->ID}' class='$role' value='{$user_object->ID}' />";
    266266
  • wp-admin/includes/class-wp-list-table.php

     
    7272        var $_pagination;
    7373
    7474        /**
    75          * Constructor. The child class should call this constructor from it's own constructor
     75         * Constructor. The child class should call this constructor from its own constructor
    7676         *
    7777         * @param array $args An associative array with information about the current table
    7878         * @access protected
  • wp-admin/includes/class-wp-plugin-install-list-table.php

     
    4040                $tabs = apply_filters( 'install_plugins_tabs', $tabs );
    4141                $nonmenu_tabs = apply_filters( 'install_plugins_nonmenu_tabs', $nonmenu_tabs );
    4242
    43                 // If a non-valid menu tab has been selected, And its not a non-menu action.
     43                // If a non-valid menu tab has been selected, And it's not a non-menu action.
    4444                if ( empty( $tab ) || ( !isset( $tabs[ $tab ] ) && !in_array( $tab, (array) $nonmenu_tabs ) ) )
    4545                        $tab = key( $tabs );
    4646
  • wp-admin/includes/class-wp-theme-install-list-table.php

     
    5151                $tabs = apply_filters( 'install_themes_tabs', $tabs );
    5252                $nonmenu_tabs = apply_filters( 'install_themes_nonmenu_tabs', $nonmenu_tabs );
    5353
    54                 // If a non-valid menu tab has been selected, And its not a non-menu action.
     54                // If a non-valid menu tab has been selected, And it's not a non-menu action.
    5555                if ( empty( $tab ) || ( ! isset( $tabs[ $tab ] ) && ! in_array( $tab, (array) $nonmenu_tabs ) ) )
    5656                        $tab = key( $tabs );
    5757
  • wp-admin/includes/class-wp-filesystem-ftpsockets.php

     
    9797                if ( ! $this->ftp->fget($temphandle, $file) ) {
    9898                        fclose($temphandle);
    9999                        unlink($temp);
    100                         return ''; //Blank document, File does exist, Its just blank.
     100                        return ''; //Blank document, File does exist, It's just blank.
    101101                }
    102102
    103103                fseek($temphandle, 0); //Skip back to the start of the file being written to
  • wp-admin/includes/class-wp-upgrader.php

     
    194194                        $source = trailingslashit($source) . trailingslashit($source_files[0]);
    195195                elseif ( count($source_files) == 0 )
    196196                        return new WP_Error( 'incompatible_archive', $this->strings['incompatible_archive'], __( 'The plugin contains no files.' ) ); //There are no files?
    197                 else //Its only a single file, The upgrader will use the foldername of this file as the destination folder. foldername is based on zip filename.
     197                else //It's only a single file, the upgrader will use the foldername of this file as the destination folder. foldername is based on zip filename.
    198198                        $source = trailingslashit($source);
    199199
    200200                //Hook ability to change the source file location..
     
    615615                $plugins_dir = $wp_filesystem->wp_plugins_dir();
    616616                $this_plugin_dir = trailingslashit( dirname($plugins_dir . $plugin) );
    617617
    618                 if ( ! $wp_filesystem->exists($this_plugin_dir) ) //If its already vanished.
     618                if ( ! $wp_filesystem->exists($this_plugin_dir) ) //If it's already vanished.
    619619                        return $removed;
    620620
    621621                // If plugin is in its own directory, recursively delete the directory.
    622                 if ( strpos($plugin, '/') && $this_plugin_dir != $plugins_dir ) //base check on if plugin includes directory separator AND that its not the root plugin folder
     622                if ( strpos($plugin, '/') && $this_plugin_dir != $plugins_dir ) //base check on if plugin includes directory separator AND that it's not the root plugin folder
    623623                        $deleted = $wp_filesystem->delete($this_plugin_dir, true);
    624624                else
    625625                        $deleted = $wp_filesystem->delete($plugins_dir . $plugin);
     
    15971597}
    15981598
    15991599/**
    1600  * Upgrade Skin helper for File uploads. This class handles the upload process and passes it as if its a local file to the Upgrade/Installer functions.
     1600 * Upgrade Skin helper for File uploads. This class handles the upload process and passes it as if it's a local file to the Upgrade/Installer functions.
    16011601 *
    16021602 * @TODO More Detailed docs, for methods as well.
    16031603 *
     
    16151615                if ( empty($_FILES[$form]['name']) && empty($_GET[$urlholder]) )
    16161616                        wp_die(__('Please select a file'));
    16171617
    1618                 //Handle a newly uploaded file, Else assume its already been uploaded
     1618                //Handle a newly uploaded file, Else assume it's already been uploaded
    16191619                if ( ! empty($_FILES) ) {
    16201620                        $overrides = array( 'test_form' => false, 'test_type' => false );
    16211621                        $file = wp_handle_upload( $_FILES[$form], $overrides );
  • wp-admin/includes/class-wp-filesystem-direct.php

     
    229229                if ( ! $recursive && $this->is_dir($file) )
    230230                        return @rmdir($file);
    231231
    232                 //At this point its a folder, and we're in recursive mode
     232                //At this point it's a folder, and we're in recursive mode
    233233                $file = trailingslashit($file);
    234234                $filelist = $this->dirlist($file, true);
    235235