From 96144d31d993e99fc8d63c420a58c1aba2460af8 Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Fri, 2 Apr 2010 03:24:18 +0000 Subject: [PATCH] Switch from wp_die() to a nice error message for siteurl!=home for network.php. see #12736 git-svn-id: https://develop.svn.wordpress.org/trunk@13929 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/network.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/wp-admin/network.php b/wp-admin/network.php index 08ea513efb..ac8c471b4c 100644 --- a/wp-admin/network.php +++ b/wp-admin/network.php @@ -67,9 +67,6 @@ function get_clean_basedomain() { if ( ! network_domain_check() && ( ! defined( 'WP_ALLOW_MULTISITE' ) || ! WP_ALLOW_MULTISITE ) ) wp_die( __( 'You must define the WP_ALLOW_MULTISITE constant as true in your wp-config.php file to allow creation of a Network.' ) ); -if ( get_option( 'siteurl' ) != get_option( 'home' ) ) - wp_die( __( 'Your WordPress address must match your Site address before creating a Network.' ) ); - $title = __( 'Create a Network of WordPress Sites' ); $parent_file = 'tools.php'; @@ -94,6 +91,12 @@ include( './admin-header.php' ); */ function network_step1( $errors = false ) { + if ( get_option( 'siteurl' ) != get_option( 'home' ) ) { + echo '

' . __('Error:') . ' ' . sprintf( __( 'Your WordPress address must match your Site address before creating a Network. See General Settings.' ), esc_url( admin_url( 'options-general.php' ) ) ) . '

'; + include ('./admin-footer.php' ); + die(); + } + $active_plugins = get_option( 'active_plugins' ); if ( ! empty( $active_plugins ) ) { echo '

' . __('Warning:') . ' ' . sprintf( __( 'Please deactivate your plugins before enabling the Network feature.' ), admin_url( 'plugins.php' ) ) . '

' . __(' Once the network is created, you may reactivate your plugins.' ) . '

';