From 546e0da910715d588c3833f3e2043ff88aca9dbc Mon Sep 17 00:00:00 2001 From: Matt Mullenweg Date: Thu, 27 May 2004 17:44:53 +0000 Subject: [PATCH] Checking for PHP < 4.1 from John Gray. git-svn-id: https://develop.svn.wordpress.org/trunk@1367 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-settings.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/wp-settings.php b/wp-settings.php index 4902989399..ed1129a514 100644 --- a/wp-settings.php +++ b/wp-settings.php @@ -27,11 +27,14 @@ $wpdb->optiongroups = $table_prefix . 'optiongroups'; $wpdb->optiongroup_options = $table_prefix . 'optiongroup_options'; $wpdb->postmeta = $table_prefix . 'postmeta'; +if ( !(phpversion() >= '4.1') ) + die( 'Your server is running PHP version ' . phpversion() . ' but WordPress requires at least 4.1' ); + + $wpdb->hide_errors(); $users = $wpdb->get_results("SELECT * FROM $wpdb->users"); -if (!$users && !strstr($_SERVER['PHP_SELF'], 'install.php')) { +if ( !$users && !strstr($_SERVER['PHP_SELF'], 'install.php') ) die("It doesn't look like you've installed WP yet. Try running install.php."); -} $wpdb->show_errors(); require (ABSPATH . WPINC . '/functions.php');