]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/network.php
WordPress 3.9-scripts
[autoinstalls/wordpress.git] / wp-admin / network.php
index c3dea684714304bc22520020f4f3621ab666b3d3..c7b115f6fa9d2a879e9383e414807d1a84a82936 100644 (file)
@@ -13,7 +13,7 @@
 define( 'WP_INSTALLING_NETWORK', true );
 
 /** WordPress Administration Bootstrap */
-require_once( './admin.php' );
+require_once( dirname( __FILE__ ) . '/admin.php' );
 
 if ( ! is_super_admin() )
        wp_die( __( 'You do not have sufficient permissions to manage options for this site.' ) );
@@ -58,13 +58,20 @@ function allow_subdomain_install() {
        return true;
 }
 /**
- * Allow subdirectory install
+ * Allow subdirectory install.
  *
  * @since 3.0.0
  * @return bool Whether subdirectory install is allowed
  */
 function allow_subdirectory_install() {
        global $wpdb;
+        /**
+         * Filter whether to enable the subdirectory install feature in Multisite.
+         *
+         * @since 3.0.0
+         *
+         * @param bool true Whether to enable the subdirectory install feature in Multisite. Default is false.
+         */
        if ( apply_filters( 'allow_subdirectory_install', false ) )
                return true;
 
@@ -123,13 +130,12 @@ get_current_screen()->set_help_sidebar(
        '<p><strong>' . __('For more information:') . '</strong></p>' .
        '<p>' . __('<a href="http://codex.wordpress.org/Create_A_Network" target="_blank">Documentation on Creating a Network</a>') . '</p>' .
        '<p>' . __('<a href="http://codex.wordpress.org/Tools_Network_Screen" target="_blank">Documentation on the Network Screen</a>') . '</p>' .
-       '<p>' . __('<a href="http://wordpress.org/support/" target="_blank">Support Forums</a>') . '</p>'
+       '<p>' . __('<a href="https://wordpress.org/support/" target="_blank">Support Forums</a>') . '</p>'
 );
 
 include( ABSPATH . 'wp-admin/admin-header.php' );
 ?>
 <div class="wrap">
-<?php screen_icon('tools'); ?>
 <h2><?php echo esc_html( $title ); ?></h2>
 
 <?php
@@ -285,14 +291,18 @@ function network_step1( $errors = false ) {
                                <th scope='row'><?php esc_html_e( 'Network Title' ); ?></th>
                                <td>
                                        <input name='sitename' type='text' size='45' value='<?php echo esc_attr( $site_name ); ?>' />
-                                       <br /><?php _e( 'What would you like to call your network?' ); ?>
+                                       <p class="description">
+                                               <?php _e( 'What would you like to call your network?' ); ?>
+                                       </p>
                                </td>
                        </tr>
                        <tr>
-                               <th scope='row'><?php esc_html_e( 'Admin E-mail Address' ); ?></th>
+                               <th scope='row'><?php esc_html_e( 'Network Admin Email' ); ?></th>
                                <td>
                                        <input name='email' type='text' size='45' value='<?php echo esc_attr( $admin_email ); ?>' />
-                                       <br /><?php _e( 'Your email address.' ); ?>
+                                       <p class="description">
+                                               <?php _e( 'Your email address.' ); ?>
+                                       </p>
                                </td>
                        </tr>
                </table>
@@ -319,9 +329,11 @@ function network_step2( $errors = false ) {
        $rewrite_base      = ! empty( $wp_siteurl_subdir ) ? ltrim( trailingslashit( $wp_siteurl_subdir ), '/' ) : '';
 
 
-       $location_of_wp_config = ABSPATH;
-       if ( ! file_exists( ABSPATH . 'wp-config.php' ) && file_exists( dirname( ABSPATH ) . '/wp-config.php' ) )
-               $location_of_wp_config = trailingslashit( dirname( ABSPATH ) );
+       $location_of_wp_config = $abspath_fix;
+       if ( ! file_exists( ABSPATH . 'wp-config.php' ) && file_exists( dirname( ABSPATH ) . '/wp-config.php' ) ) {
+               $location_of_wp_config = dirname( $abspath_fix );
+       }
+       $location_of_wp_config = trailingslashit( $location_of_wp_config );
 
        // Wildcard DNS message.
        if ( is_wp_error( $errors ) )
@@ -457,9 +469,11 @@ define('BLOG_ID_CURRENT_SITE', 1);</textarea>
     </system.webServer>
 </configuration>';
 
-       ?>
-               <li><p><?php printf( __( 'Add the following to your <code>web.config</code> file in <code>%s</code>, replacing other WordPress rules:' ), $home_path ); ?></p>
-               <?php
+               echo '<li><p>';
+               /* translators: 1: a filename like .htaccess. 2: a file path. */
+               printf( __( 'Add the following to your %1$s file in %2$s, <strong>replacing</strong> other WordPress rules:' ),
+                       '<code>web.config</code>', '<code>' . $home_path . '</code>' );
+               echo '</p>';
                if ( ! $subdomain_install && WP_CONTENT_DIR != ABSPATH . 'wp-content' )
                        echo '<p><strong>' . __('Warning:') . ' ' . __( 'Subdirectory networks may not be fully compatible with custom wp-content directories.' ) . '</strong></p>';
                ?>
@@ -491,9 +505,11 @@ RewriteRule ^{$subdir_match}(.*\.php)$ {$rewrite_base}$subdir_replacement_12 [L]
 RewriteRule . index.php [L]
 EOF;
 
-               ?>
-               <li><p><?php printf( __( 'Add the following to your <code>.htaccess</code> file in <code>%s</code>, replacing other WordPress rules:' ), $home_path ); ?></p>
-               <?php
+               echo '<li><p>';
+               /* translators: 1: a filename like .htaccess. 2: a file path. */
+               printf( __( 'Add the following to your %1$s file in %2$s, <strong>replacing</strong> other WordPress rules:' ),
+                       '<code>.htaccess</code>', '<code>' . $home_path . '</code>' );
+               echo '</p>';
                if ( ! $subdomain_install && WP_CONTENT_DIR != ABSPATH . 'wp-content' )
                        echo '<p><strong>' . __('Warning:') . ' ' . __( 'Subdirectory networks may not be fully compatible with custom wp-content directories.' ) . '</strong></p>';
                ?>