WordPress.org

Make WordPress Core

Ticket #21316: 21316.2.patch

File 21316.2.patch, 894 bytes (added by SergeyBiryukov, 6 years ago)
  • wp-includes/load.php

     
    102102 */
    103103function wp_check_php_mysql_versions() {
    104104        global $required_php_version, $wp_version;
     105
    105106        $php_version = phpversion();
    106         if ( version_compare( $required_php_version, $php_version, '>' ) ) {
     107        if ( version_compare( '5.0.0', $php_version, '>' ) ) {
     108                die( sprintf( 'Your server is running PHP version %1$s but WordPress %2$s requires at least %3$s.', $php_version, $wp_version, $required_php_version ) );
     109        } elseif ( version_compare( $required_php_version, $php_version, '>' ) ) {
    107110                wp_load_translations_early();
    108111                wp_die( sprintf( __( 'Your server is running PHP version %1$s but WordPress %2$s requires at least %3$s.' ), $php_version, $wp_version, $required_php_version ) );
    109112        }