Ticket #15620: network-setup-fix-bad-base.patch
File network-setup-fix-bad-base.patch, 2.2 KB (added by , 15 years ago) |
---|
-
wp-admin/network.php
137 137 if ( get_option( 'siteurl' ) != get_option( 'home' ) ) { 138 138 echo '<div class="error"><p><strong>' . __('Error:') . '</strong> ' . sprintf( __( 'Your <strong>WordPress address</strong> must match your <strong>Site address</strong> before creating a Network. See <a href="%s">General Settings</a>.' ), esc_url( admin_url( 'options-general.php' ) ) ) . '</p></div>'; 139 139 echo '</div>'; 140 include ( './admin-footer.php' );140 include ( ABSPATH . 'wp-admin/admin-footer.php' ); 141 141 die(); 142 142 } 143 143 144 144 if ( defined('DO_NOT_UPGRADE_GLOBAL_TABLES') ) { 145 145 echo '<div class="error"><p><strong>' . __('Error:') . '</strong> ' . __( 'The constant DO_NOT_UPGRADE_GLOBAL_TABLES cannot be defined when creating a network.' ) . '</p></div>'; 146 146 echo '</div>'; 147 include ( './admin-footer.php' );147 include ( ABSPATH . 'wp-admin/admin-footer.php' ); 148 148 die(); 149 149 } 150 150 … … 152 152 if ( ! empty( $active_plugins ) ) { 153 153 echo '<div class="updated"><p><strong>' . __('Warning:') . '</strong> ' . sprintf( __( 'Please <a href="%s">deactivate your plugins</a> before enabling the Network feature.' ), admin_url( 'plugins.php?plugin_status=active' ) ) . '</p></div><p>' . __( 'Once the network is created, you may reactivate your plugins.' ) . '</p>'; 154 154 echo '</div>'; 155 include( './admin-footer.php' );155 include( ABSPATH . 'wp-admin/admin-footer.php' ); 156 156 die(); 157 157 } 158 158 … … 163 163 echo '<p>' . sprintf( __( 'You cannot use port numbers such as <code>%s</code>.' ), $has_ports ) . '</p>'; 164 164 echo '<a href="' . esc_url( admin_url() ) . '">' . __( 'Return to Dashboard' ) . '</a>'; 165 165 echo '</div>'; 166 include( './admin-footer.php' );166 include( ABSPATH . 'wp-admin/admin-footer.php' ); 167 167 die(); 168 168 } 169 169 … … 511 511 } 512 512 } 513 513 514 $base = trailingslashit( stripslashes( dirname( dirname( $_SERVER['SCRIPT_NAME'] ) ) ) ); 514 if ( $_POST ) { 515 515 516 if ( $_POST ) { 516 $base = trailingslashit( stripslashes( dirname( dirname( $_SERVER['SCRIPT_NAME'] ) ) ) ); 517 517 518 check_admin_referer( 'install-network-1' ); 518 519 519 520 require_once( ABSPATH . 'wp-admin/includes/upgrade.php' );