Make WordPress Core

Changeset 31391


Ignore:
Timestamp:
02/09/2015 10:27:43 PM (10 years ago)
Author:
pento
Message:

WPDB: When checking to see if we can use utf8mb4, we also need to make sure PHP's MySQL client library is capable of using utf8mb4.

See #21212

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/wp-db.php

    r31374 r31391  
    28022802                return version_compare( $version, '5.0.7', '>=' );
    28032803            case 'utf8mb4' :      // @since 4.1.0
    2804                 return version_compare( $version, '5.5.3', '>=' );
     2804                if ( version_compare( $version, '5.5.3', '<' ) ) {
     2805                    return false;
     2806                }
     2807                if ( $this->use_mysqli ) {
     2808                    return mysqli_get_client_version( $this->dbh ) >= 50503;
     2809                } else {
     2810                    return mysql_get_client_version( $this->dbh ) >= 50503;
     2811                }
    28052812        }
    28062813
Note: See TracChangeset for help on using the changeset viewer.