Changeset 42455
- Timestamp:
- 01/15/2018 10:49:15 PM (7 years ago)
- Location:
- branches/4.9
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/4.9
-
branches/4.9/src/wp-includes/wp-db.php
r42229 r42455 571 571 $this->show_errors(); 572 572 573 /* Use ext/mysqli if it exists and: 574 * - WP_USE_EXT_MYSQL is defined as false, or 575 * - We are a development version of WordPress, or 576 * - We are running PHP 5.5 or greater, or 577 * - ext/mysql is not loaded. 578 */ 573 // Use ext/mysqli if it exists unless WP_USE_EXT_MYSQL is defined as true 579 574 if ( function_exists( 'mysqli_connect' ) ) { 575 $this->use_mysqli = true; 576 580 577 if ( defined( 'WP_USE_EXT_MYSQL' ) ) { 581 578 $this->use_mysqli = ! WP_USE_EXT_MYSQL; 582 } elseif ( version_compare( phpversion(), '5.5', '>=' ) || ! function_exists( 'mysql_connect' ) ) {583 $this->use_mysqli = true;584 } elseif ( false !== strpos( $GLOBALS['wp_version'], '-' ) ) {585 $this->use_mysqli = true;586 579 } 587 580 }
Note: See TracChangeset
for help on using the changeset viewer.