Completed
Push — master ( a7cd2a...eabd6c )
by Stephen
38:42
created
src/wp-admin/network/setup.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -8,9 +8,9 @@
 block discarded – undo
8 8
  */
9 9
 
10 10
 /** Load WordPress Administration Bootstrap */
11
-require_once( dirname( __FILE__ ) . '/admin.php' );
11
+require_once(dirname(__FILE__).'/admin.php');
12 12
 
13
-if ( ! is_multisite() )
14
-	wp_die( __( 'Multisite support is not enabled.' ) );
13
+if ( ! is_multisite())
14
+	wp_die(__('Multisite support is not enabled.'));
15 15
 
16
-require( ABSPATH . 'wp-admin/network.php' );
16
+require(ABSPATH.'wp-admin/network.php');
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,8 @@
 block discarded – undo
10 10
 /** Load WordPress Administration Bootstrap */
11 11
 require_once( dirname( __FILE__ ) . '/admin.php' );
12 12
 
13
-if ( ! is_multisite() )
13
+if ( ! is_multisite() ) {
14 14
 	wp_die( __( 'Multisite support is not enabled.' ) );
15
+}
15 16
 
16 17
 require( ABSPATH . 'wp-admin/about.php' );
Please login to merge, or discard this patch.
src/wp-admin/network/theme-editor.php 3 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -8,9 +8,9 @@
 block discarded – undo
8 8
  */
9 9
 
10 10
 /** Load WordPress Administration Bootstrap */
11
-require_once( dirname( __FILE__ ) . '/admin.php' );
11
+require_once(dirname(__FILE__).'/admin.php');
12 12
 
13
-if ( ! is_multisite() )
14
-	wp_die( __( 'Multisite support is not enabled.' ) );
13
+if ( ! is_multisite())
14
+	wp_die(__('Multisite support is not enabled.'));
15 15
 
16
-require( ABSPATH . 'wp-admin/theme-editor.php' );
16
+require(ABSPATH.'wp-admin/theme-editor.php');
Please login to merge, or discard this patch.
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,11 +1,11 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Theme editor network administration panel.
4
- *
5
- * @package WordPress
6
- * @subpackage Multisite
7
- * @since 3.1.0
8
- */
3
+		 * Theme editor network administration panel.
4
+		 *
5
+		 * @package WordPress
6
+		 * @subpackage Multisite
7
+		 * @since 3.1.0
8
+		 */
9 9
 
10 10
 /** Load WordPress Administration Bootstrap */
11 11
 require_once( dirname( __FILE__ ) . '/admin.php' );
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,8 @@
 block discarded – undo
10 10
 /** Load WordPress Administration Bootstrap */
11 11
 require_once( dirname( __FILE__ ) . '/admin.php' );
12 12
 
13
-if ( ! is_multisite() )
13
+if ( ! is_multisite() ) {
14 14
 	wp_die( __( 'Multisite support is not enabled.' ) );
15
+}
15 16
 
16 17
 require( ABSPATH . 'wp-admin/about.php' );
Please login to merge, or discard this patch.
src/wp-admin/network/index.php 2 patches
Spacing   +33 added lines, -33 removed lines patch added patch discarded remove patch
@@ -8,64 +8,64 @@  discard block
 block discarded – undo
8 8
  */
9 9
 
10 10
 /** Load WordPress Administration Bootstrap */
11
-require_once( dirname( __FILE__ ) . '/admin.php' );
11
+require_once(dirname(__FILE__).'/admin.php');
12 12
 
13 13
 /** Load WordPress dashboard API */
14
-require_once( ABSPATH . 'wp-admin/includes/dashboard.php' );
14
+require_once(ABSPATH.'wp-admin/includes/dashboard.php');
15 15
 
16
-if ( !is_multisite() )
17
-	wp_die( __( 'Multisite support is not enabled.' ) );
16
+if ( ! is_multisite())
17
+	wp_die(__('Multisite support is not enabled.'));
18 18
 
19
-if ( ! current_user_can( 'manage_network' ) )
20
-	wp_die( __( 'You do not have permission to access this page.' ), 403 );
19
+if ( ! current_user_can('manage_network'))
20
+	wp_die(__('You do not have permission to access this page.'), 403);
21 21
 
22
-$title = __( 'Dashboard' );
22
+$title = __('Dashboard');
23 23
 $parent_file = 'index.php';
24 24
 
25
-$overview = '<p>' . __( 'Welcome to your Network Admin. This area of the Administration Screens is used for managing all aspects of your Multisite Network.' ) . '</p>';
26
-$overview .= '<p>' . __( 'From here you can:' ) . '</p>';
27
-$overview .= '<ul><li>' . __( 'Add and manage sites or users' ) . '</li>';
28
-$overview .= '<li>' . __( 'Install and activate themes or plugins' ) . '</li>';
29
-$overview .= '<li>' . __( 'Update your network' ) . '</li>';
30
-$overview .= '<li>' . __( 'Modify global network settings' ) . '</li></ul>';
25
+$overview = '<p>'.__('Welcome to your Network Admin. This area of the Administration Screens is used for managing all aspects of your Multisite Network.').'</p>';
26
+$overview .= '<p>'.__('From here you can:').'</p>';
27
+$overview .= '<ul><li>'.__('Add and manage sites or users').'</li>';
28
+$overview .= '<li>'.__('Install and activate themes or plugins').'</li>';
29
+$overview .= '<li>'.__('Update your network').'</li>';
30
+$overview .= '<li>'.__('Modify global network settings').'</li></ul>';
31 31
 
32
-get_current_screen()->add_help_tab( array(
32
+get_current_screen()->add_help_tab(array(
33 33
 	'id'      => 'overview',
34
-	'title'   => __( 'Overview' ),
34
+	'title'   => __('Overview'),
35 35
 	'content' => $overview
36
-) );
36
+));
37 37
 
38
-$quick_tasks = '<p>' . __( 'The Right Now widget on this screen provides current user and site counts on your network.' ) . '</p>';
39
-$quick_tasks .= '<ul><li>' . __( 'To add a new user, <strong>click Create a New User</strong>.' ) . '</li>';
40
-$quick_tasks .= '<li>' . __( 'To add a new site, <strong>click Create a New Site</strong>.' ) . '</li></ul>';
41
-$quick_tasks .= '<p>' . __( 'To search for a user or site, use the search boxes.' ) . '</p>';
42
-$quick_tasks .= '<ul><li>' . __( 'To search for a user, <strong>enter an email address or username</strong>. Use a wildcard to search for a partial username, such as user&#42;.' ) . '</li>';
43
-$quick_tasks .= '<li>' . __( 'To search for a site, <strong>enter the path or domain</strong>.' ) . '</li></ul>';
38
+$quick_tasks = '<p>'.__('The Right Now widget on this screen provides current user and site counts on your network.').'</p>';
39
+$quick_tasks .= '<ul><li>'.__('To add a new user, <strong>click Create a New User</strong>.').'</li>';
40
+$quick_tasks .= '<li>'.__('To add a new site, <strong>click Create a New Site</strong>.').'</li></ul>';
41
+$quick_tasks .= '<p>'.__('To search for a user or site, use the search boxes.').'</p>';
42
+$quick_tasks .= '<ul><li>'.__('To search for a user, <strong>enter an email address or username</strong>. Use a wildcard to search for a partial username, such as user&#42;.').'</li>';
43
+$quick_tasks .= '<li>'.__('To search for a site, <strong>enter the path or domain</strong>.').'</li></ul>';
44 44
 
45
-get_current_screen()->add_help_tab( array(
45
+get_current_screen()->add_help_tab(array(
46 46
 	'id'      => 'quick-tasks',
47
-	'title'   => __( 'Quick Tasks' ),
47
+	'title'   => __('Quick Tasks'),
48 48
 	'content' => $quick_tasks
49
-) );
49
+));
50 50
 
51 51
 get_current_screen()->set_help_sidebar(
52
-	'<p><strong>' . __('For more information:') . '</strong></p>' .
53
-	'<p>' . __('<a href="https://codex.wordpress.org/Network_Admin" target="_blank">Documentation on the Network Admin</a>') . '</p>' .
54
-	'<p>' . __('<a href="https://wordpress.org/support/forum/multisite/" target="_blank">Support Forums</a>') . '</p>'
52
+	'<p><strong>'.__('For more information:').'</strong></p>'.
53
+	'<p>'.__('<a href="https://codex.wordpress.org/Network_Admin" target="_blank">Documentation on the Network Admin</a>').'</p>'.
54
+	'<p>'.__('<a href="https://wordpress.org/support/forum/multisite/" target="_blank">Support Forums</a>').'</p>'
55 55
 );
56 56
 
57 57
 wp_dashboard_setup();
58 58
 
59
-wp_enqueue_script( 'dashboard' );
60
-wp_enqueue_script( 'plugin-install' );
59
+wp_enqueue_script('dashboard');
60
+wp_enqueue_script('plugin-install');
61 61
 add_thickbox();
62 62
 
63
-require_once( ABSPATH . 'wp-admin/admin-header.php' );
63
+require_once(ABSPATH.'wp-admin/admin-header.php');
64 64
 
65 65
 ?>
66 66
 
67 67
 <div class="wrap">
68
-<h1><?php echo esc_html( $title ); ?></h1>
68
+<h1><?php echo esc_html($title); ?></h1>
69 69
 
70 70
 <div id="dashboard-widgets-wrap">
71 71
 
@@ -76,4 +76,4 @@  discard block
 block discarded – undo
76 76
 
77 77
 </div><!-- wrap -->
78 78
 
79
-<?php include( ABSPATH . 'wp-admin/admin-footer.php' ); ?>
79
+<?php include(ABSPATH.'wp-admin/admin-footer.php'); ?>
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,11 +13,13 @@
 block discarded – undo
13 13
 /** Load WordPress dashboard API */
14 14
 require_once( ABSPATH . 'wp-admin/includes/dashboard.php' );
15 15
 
16
-if ( !is_multisite() )
16
+if ( !is_multisite() ) {
17 17
 	wp_die( __( 'Multisite support is not enabled.' ) );
18
+}
18 19
 
19
-if ( ! current_user_can( 'manage_network' ) )
20
+if ( ! current_user_can( 'manage_network' ) ) {
20 21
 	wp_die( __( 'You do not have permission to access this page.' ), 403 );
22
+}
21 23
 
22 24
 $title = __( 'Dashboard' );
23 25
 $parent_file = 'index.php';
Please login to merge, or discard this patch.
src/wp-admin/network/theme-install.php 2 patches
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -7,13 +7,13 @@
 block discarded – undo
7 7
  * @since 3.1.0
8 8
  */
9 9
 
10
-if ( isset( $_GET['tab'] ) && ( 'theme-information' == $_GET['tab'] ) )
11
-	define( 'IFRAME_REQUEST', true );
10
+if (isset($_GET['tab']) && ('theme-information' == $_GET['tab']))
11
+	define('IFRAME_REQUEST', true);
12 12
 
13 13
 /** Load WordPress Administration Bootstrap */
14
-require_once( dirname( __FILE__ ) . '/admin.php' );
14
+require_once(dirname(__FILE__).'/admin.php');
15 15
 
16
-if ( ! is_multisite() )
17
-	wp_die( __( 'Multisite support is not enabled.' ) );
16
+if ( ! is_multisite())
17
+	wp_die(__('Multisite support is not enabled.'));
18 18
 
19
-require( ABSPATH . 'wp-admin/theme-install.php' );
19
+require(ABSPATH.'wp-admin/theme-install.php');
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -7,13 +7,15 @@
 block discarded – undo
7 7
  * @since 3.1.0
8 8
  */
9 9
 
10
-if ( isset( $_GET['tab'] ) && ( 'theme-information' == $_GET['tab'] ) )
10
+if ( isset( $_GET['tab'] ) && ( 'theme-information' == $_GET['tab'] ) ) {
11 11
 	define( 'IFRAME_REQUEST', true );
12
+}
12 13
 
13 14
 /** Load WordPress Administration Bootstrap */
14 15
 require_once( dirname( __FILE__ ) . '/admin.php' );
15 16
 
16
-if ( ! is_multisite() )
17
+if ( ! is_multisite() ) {
17 18
 	wp_die( __( 'Multisite support is not enabled.' ) );
19
+}
18 20
 
19 21
 require( ABSPATH . 'wp-admin/theme-install.php' );
Please login to merge, or discard this patch.
src/wp-admin/network/edit.php 2 patches
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -8,13 +8,13 @@  discard block
 block discarded – undo
8 8
  */
9 9
 
10 10
 /** Load WordPress Administration Bootstrap */
11
-require_once( dirname( __FILE__ ) . '/admin.php' );
11
+require_once(dirname(__FILE__).'/admin.php');
12 12
 
13
-if ( ! is_multisite() )
14
-	wp_die( __( 'Multisite support is not enabled.' ) );
13
+if ( ! is_multisite())
14
+	wp_die(__('Multisite support is not enabled.'));
15 15
 
16
-if ( empty( $_GET['action'] ) ) {
17
-	wp_redirect( network_admin_url() );
16
+if (empty($_GET['action'])) {
17
+	wp_redirect(network_admin_url());
18 18
 	exit;
19 19
 }
20 20
 
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
  *
27 27
  * @since 3.0.0
28 28
  */
29
-do_action( 'wpmuadminedit' );
29
+do_action('wpmuadminedit');
30 30
 
31 31
 /**
32 32
  * Fires the requested handler action.
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
  *
37 37
  * @since 3.1.0
38 38
  */
39
-do_action( 'network_admin_edit_' . $_GET['action'] );
39
+do_action('network_admin_edit_'.$_GET['action']);
40 40
 
41
-wp_redirect( network_admin_url() );
41
+wp_redirect(network_admin_url());
42 42
 exit();
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,8 @@
 block discarded – undo
10 10
 /** Load WordPress Administration Bootstrap */
11 11
 require_once( dirname( __FILE__ ) . '/admin.php' );
12 12
 
13
-if ( ! is_multisite() )
13
+if ( ! is_multisite() ) {
14 14
 	wp_die( __( 'Multisite support is not enabled.' ) );
15
+}
15 16
 
16 17
 require( ABSPATH . 'wp-admin/about.php' );
Please login to merge, or discard this patch.
src/wp-admin/network/menu.php 2 patches
Spacing   +27 added lines, -27 removed lines patch added patch discarded remove patch
@@ -10,53 +10,53 @@
 block discarded – undo
10 10
 /* translators: Network menu item */
11 11
 $menu[2] = array(__('Dashboard'), 'manage_network', 'index.php', '', 'menu-top menu-top-first menu-icon-dashboard', 'menu-dashboard', 'dashicons-dashboard');
12 12
 
13
-$submenu['index.php'][0] = array( __( 'Home' ), 'read', 'index.php' );
13
+$submenu['index.php'][0] = array(__('Home'), 'read', 'index.php');
14 14
 
15 15
 $update_data = wp_get_update_data();
16
-if ( $update_data['counts']['total'] ) {
17
-	$submenu['index.php'][10] = array( sprintf( __( 'Updates %s' ), "<span class='update-plugins count-{$update_data['counts']['total']}' title='{$update_data['title']}'><span class='update-count'>" . number_format_i18n( $update_data['counts']['total'] ) . "</span></span>" ), 'update_core', 'update-core.php' );
16
+if ($update_data['counts']['total']) {
17
+	$submenu['index.php'][10] = array(sprintf(__('Updates %s'), "<span class='update-plugins count-{$update_data['counts']['total']}' title='{$update_data['title']}'><span class='update-count'>".number_format_i18n($update_data['counts']['total'])."</span></span>"), 'update_core', 'update-core.php');
18 18
 } else {
19
-	$submenu['index.php'][10] = array( __( 'Updates' ), 'update_core', 'update-core.php' );
19
+	$submenu['index.php'][10] = array(__('Updates'), 'update_core', 'update-core.php');
20 20
 }
21 21
 
22
-$submenu['index.php'][15] = array( __( 'Upgrade Network' ), 'manage_network', 'upgrade.php' );
22
+$submenu['index.php'][15] = array(__('Upgrade Network'), 'manage_network', 'upgrade.php');
23 23
 
24
-$menu[4] = array( '', 'read', 'separator1', '', 'wp-menu-separator' );
24
+$menu[4] = array('', 'read', 'separator1', '', 'wp-menu-separator');
25 25
 
26 26
 /* translators: Sites menu item */
27 27
 $menu[5] = array(__('Sites'), 'manage_sites', 'sites.php', '', 'menu-top menu-icon-site', 'menu-site', 'dashicons-admin-network');
28
-$submenu['sites.php'][5]  = array( __('All Sites'), 'manage_sites', 'sites.php' );
29
-$submenu['sites.php'][10]  = array( _x('Add New', 'site'), 'create_sites', 'site-new.php' );
28
+$submenu['sites.php'][5] = array(__('All Sites'), 'manage_sites', 'sites.php');
29
+$submenu['sites.php'][10] = array(_x('Add New', 'site'), 'create_sites', 'site-new.php');
30 30
 
31 31
 $menu[10] = array(__('Users'), 'manage_network_users', 'users.php', '', 'menu-top menu-icon-users', 'menu-users', 'dashicons-admin-users');
32
-$submenu['users.php'][5]  = array( __('All Users'), 'manage_network_users', 'users.php' );
33
-$submenu['users.php'][10]  = array( _x('Add New', 'user'), 'create_users', 'user-new.php' );
32
+$submenu['users.php'][5] = array(__('All Users'), 'manage_network_users', 'users.php');
33
+$submenu['users.php'][10] = array(_x('Add New', 'user'), 'create_users', 'user-new.php');
34 34
 
35
-if ( current_user_can( 'update_themes' ) && $update_data['counts']['themes'] ) {
36
-	$menu[15] = array(sprintf( __( 'Themes %s' ), "<span class='update-plugins count-{$update_data['counts']['themes']}'><span class='theme-count'>" . number_format_i18n( $update_data['counts']['themes'] ) . "</span></span>" ), 'manage_network_themes', 'themes.php', '', 'menu-top menu-icon-appearance', 'menu-appearance', 'dashicons-admin-appearance' );
35
+if (current_user_can('update_themes') && $update_data['counts']['themes']) {
36
+	$menu[15] = array(sprintf(__('Themes %s'), "<span class='update-plugins count-{$update_data['counts']['themes']}'><span class='theme-count'>".number_format_i18n($update_data['counts']['themes'])."</span></span>"), 'manage_network_themes', 'themes.php', '', 'menu-top menu-icon-appearance', 'menu-appearance', 'dashicons-admin-appearance');
37 37
 } else {
38
-	$menu[15] = array( __( 'Themes' ), 'manage_network_themes', 'themes.php', '', 'menu-top menu-icon-appearance', 'menu-appearance', 'dashicons-admin-appearance' );
38
+	$menu[15] = array(__('Themes'), 'manage_network_themes', 'themes.php', '', 'menu-top menu-icon-appearance', 'menu-appearance', 'dashicons-admin-appearance');
39 39
 }
40
-$submenu['themes.php'][5]  = array( __('Installed Themes'), 'manage_network_themes', 'themes.php' );
41
-$submenu['themes.php'][10] = array( _x('Add New', 'theme'), 'install_themes', 'theme-install.php' );
42
-$submenu['themes.php'][15] = array( _x('Editor', 'theme editor'), 'edit_themes', 'theme-editor.php' );
40
+$submenu['themes.php'][5]  = array(__('Installed Themes'), 'manage_network_themes', 'themes.php');
41
+$submenu['themes.php'][10] = array(_x('Add New', 'theme'), 'install_themes', 'theme-install.php');
42
+$submenu['themes.php'][15] = array(_x('Editor', 'theme editor'), 'edit_themes', 'theme-editor.php');
43 43
 
44
-if ( current_user_can( 'update_plugins' ) && $update_data['counts']['plugins'] ) {
45
-	$menu[20] = array( sprintf( __( 'Plugins %s' ), "<span class='update-plugins count-{$update_data['counts']['plugins']}'><span class='plugin-count'>" . number_format_i18n( $update_data['counts']['plugins'] ) . "</span></span>" ), 'manage_network_plugins', 'plugins.php', '', 'menu-top menu-icon-plugins', 'menu-plugins', 'dashicons-admin-plugins');
44
+if (current_user_can('update_plugins') && $update_data['counts']['plugins']) {
45
+	$menu[20] = array(sprintf(__('Plugins %s'), "<span class='update-plugins count-{$update_data['counts']['plugins']}'><span class='plugin-count'>".number_format_i18n($update_data['counts']['plugins'])."</span></span>"), 'manage_network_plugins', 'plugins.php', '', 'menu-top menu-icon-plugins', 'menu-plugins', 'dashicons-admin-plugins');
46 46
 } else {
47
-	$menu[20] = array( __('Plugins'), 'manage_network_plugins', 'plugins.php', '', 'menu-top menu-icon-plugins', 'menu-plugins', 'dashicons-admin-plugins' );
47
+	$menu[20] = array(__('Plugins'), 'manage_network_plugins', 'plugins.php', '', 'menu-top menu-icon-plugins', 'menu-plugins', 'dashicons-admin-plugins');
48 48
 }
49
-$submenu['plugins.php'][5]  = array( __('Installed Plugins'), 'manage_network_plugins', 'plugins.php' );
50
-$submenu['plugins.php'][10] = array( _x('Add New', 'plugin'), 'install_plugins', 'plugin-install.php' );
51
-$submenu['plugins.php'][15] = array( _x('Editor', 'plugin editor'), 'edit_plugins', 'plugin-editor.php' );
49
+$submenu['plugins.php'][5]  = array(__('Installed Plugins'), 'manage_network_plugins', 'plugins.php');
50
+$submenu['plugins.php'][10] = array(_x('Add New', 'plugin'), 'install_plugins', 'plugin-install.php');
51
+$submenu['plugins.php'][15] = array(_x('Editor', 'plugin editor'), 'edit_plugins', 'plugin-editor.php');
52 52
 
53 53
 $menu[25] = array(__('Settings'), 'manage_network_options', 'settings.php', '', 'menu-top menu-icon-settings', 'menu-settings', 'dashicons-admin-settings');
54
-if ( defined( 'MULTISITE' ) && defined( 'WP_ALLOW_MULTISITE' ) && WP_ALLOW_MULTISITE ) {
55
-	$submenu['settings.php'][5]  = array( __('Network Settings'), 'manage_network_options', 'settings.php' );
56
-	$submenu['settings.php'][10] = array( __('Network Setup'), 'manage_network_options', 'setup.php' );
54
+if (defined('MULTISITE') && defined('WP_ALLOW_MULTISITE') && WP_ALLOW_MULTISITE) {
55
+	$submenu['settings.php'][5]  = array(__('Network Settings'), 'manage_network_options', 'settings.php');
56
+	$submenu['settings.php'][10] = array(__('Network Setup'), 'manage_network_options', 'setup.php');
57 57
 }
58 58
 unset($update_data);
59 59
 
60
-$menu[99] = array( '', 'exist', 'separator-last', '', 'wp-menu-separator' );
60
+$menu[99] = array('', 'exist', 'separator-last', '', 'wp-menu-separator');
61 61
 
62
-require_once(ABSPATH . 'wp-admin/includes/menu.php');
63 62
\ No newline at end of file
63
+require_once(ABSPATH.'wp-admin/includes/menu.php');
64 64
\ No newline at end of file
Please login to merge, or discard this patch.
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,11 +1,11 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Build Network Administration Menu.
4
- *
5
- * @package WordPress
6
- * @subpackage Multisite
7
- * @since 3.1.0
8
- */
3
+	 * Build Network Administration Menu.
4
+	 *
5
+	 * @package WordPress
6
+	 * @subpackage Multisite
7
+	 * @since 3.1.0
8
+	 */
9 9
 
10 10
 /* translators: Network menu item */
11 11
 $menu[2] = array(__('Dashboard'), 'manage_network', 'index.php', '', 'menu-top menu-top-first menu-icon-dashboard', 'menu-dashboard', 'dashicons-dashboard');
Please login to merge, or discard this patch.
src/wp-admin/network/update.php 3 patches
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -7,13 +7,13 @@
 block discarded – undo
7 7
  * @since 3.1.0
8 8
  */
9 9
 
10
-if ( isset( $_GET['action'] ) && in_array( $_GET['action'], array( 'update-selected', 'activate-plugin', 'update-selected-themes' ) ) )
11
-	define( 'IFRAME_REQUEST', true );
10
+if (isset($_GET['action']) && in_array($_GET['action'], array('update-selected', 'activate-plugin', 'update-selected-themes')))
11
+	define('IFRAME_REQUEST', true);
12 12
 
13 13
 /** Load WordPress Administration Bootstrap */
14
-require_once( dirname( __FILE__ ) . '/admin.php' );
14
+require_once(dirname(__FILE__).'/admin.php');
15 15
 
16
-if ( ! is_multisite() )
17
-	wp_die( __( 'Multisite support is not enabled.' ) );
16
+if ( ! is_multisite())
17
+	wp_die(__('Multisite support is not enabled.'));
18 18
 
19
-require( ABSPATH . 'wp-admin/update.php' );
19
+require(ABSPATH.'wp-admin/update.php');
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -7,13 +7,15 @@
 block discarded – undo
7 7
  * @since 3.1.0
8 8
  */
9 9
 
10
-if ( isset( $_GET['action'] ) && in_array( $_GET['action'], array( 'update-selected', 'activate-plugin', 'update-selected-themes' ) ) )
10
+if ( isset( $_GET['action'] ) && in_array( $_GET['action'], array( 'update-selected', 'activate-plugin', 'update-selected-themes' ) ) ) {
11 11
 	define( 'IFRAME_REQUEST', true );
12
+}
12 13
 
13 14
 /** Load WordPress Administration Bootstrap */
14 15
 require_once( dirname( __FILE__ ) . '/admin.php' );
15 16
 
16
-if ( ! is_multisite() )
17
+if ( ! is_multisite() ) {
17 18
 	wp_die( __( 'Multisite support is not enabled.' ) );
19
+}
18 20
 
19 21
 require( ABSPATH . 'wp-admin/update.php' );
Please login to merge, or discard this patch.
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,11 +1,11 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Update/Install Plugin/Theme network administration panel.
4
- *
5
- * @package WordPress
6
- * @subpackage Multisite
7
- * @since 3.1.0
8
- */
3
+	 * Update/Install Plugin/Theme network administration panel.
4
+	 *
5
+	 * @package WordPress
6
+	 * @subpackage Multisite
7
+	 * @since 3.1.0
8
+	 */
9 9
 
10 10
 if ( isset( $_GET['action'] ) && in_array( $_GET['action'], array( 'update-selected', 'activate-plugin', 'update-selected-themes' ) ) )
11 11
 	define( 'IFRAME_REQUEST', true );
Please login to merge, or discard this patch.
src/wp-admin/network/upgrade.php 2 patches
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -10,8 +10,9 @@  discard block
 block discarded – undo
10 10
 /** Load WordPress Administration Bootstrap */
11 11
 require_once( dirname( __FILE__ ) . '/admin.php' );
12 12
 
13
-if ( ! is_multisite() )
13
+if ( ! is_multisite() ) {
14 14
 	wp_die( __( 'Multisite support is not enabled.' ) );
15
+}
15 16
 
16 17
 require_once( ABSPATH . WPINC . '/http.php' );
17 18
 
@@ -35,8 +36,9 @@  discard block
 block discarded – undo
35 36
 
36 37
 require_once( ABSPATH . 'wp-admin/admin-header.php' );
37 38
 
38
-if ( ! current_user_can( 'manage_network' ) )
39
+if ( ! current_user_can( 'manage_network' ) ) {
39 40
 	wp_die( __( 'You do not have permission to access this page.' ), 403 );
41
+}
40 42
 
41 43
 echo '<div class="wrap">';
42 44
 echo '<h1>' . __( 'Upgrade Network' ) . '</h1>';
Please login to merge, or discard this patch.
Spacing   +43 added lines, -43 removed lines patch added patch discarded remove patch
@@ -8,75 +8,75 @@  discard block
 block discarded – undo
8 8
  */
9 9
 
10 10
 /** Load WordPress Administration Bootstrap */
11
-require_once( dirname( __FILE__ ) . '/admin.php' );
11
+require_once(dirname(__FILE__).'/admin.php');
12 12
 
13
-if ( ! is_multisite() )
14
-	wp_die( __( 'Multisite support is not enabled.' ) );
13
+if ( ! is_multisite())
14
+	wp_die(__('Multisite support is not enabled.'));
15 15
 
16
-require_once( ABSPATH . WPINC . '/http.php' );
16
+require_once(ABSPATH.WPINC.'/http.php');
17 17
 
18
-$title = __( 'Upgrade Network' );
18
+$title = __('Upgrade Network');
19 19
 $parent_file = 'upgrade.php';
20 20
 
21
-get_current_screen()->add_help_tab( array(
21
+get_current_screen()->add_help_tab(array(
22 22
 	'id'      => 'overview',
23 23
 	'title'   => __('Overview'),
24 24
 	'content' =>
25
-		'<p>' . __('Only use this screen once you have updated to a new version of WordPress through Updates/Available Updates (via the Network Administration navigation menu or the Toolbar). Clicking the Upgrade Network button will step through each site in the network, five at a time, and make sure any database updates are applied.') . '</p>' .
26
-		'<p>' . __('If a version update to core has not happened, clicking this button won&#8217;t affect anything.') . '</p>' .
27
-		'<p>' . __('If this process fails for any reason, users logging in to their sites will force the same update.') . '</p>'
28
-) );
25
+		'<p>'.__('Only use this screen once you have updated to a new version of WordPress through Updates/Available Updates (via the Network Administration navigation menu or the Toolbar). Clicking the Upgrade Network button will step through each site in the network, five at a time, and make sure any database updates are applied.').'</p>'.
26
+		'<p>'.__('If a version update to core has not happened, clicking this button won&#8217;t affect anything.').'</p>'.
27
+		'<p>'.__('If this process fails for any reason, users logging in to their sites will force the same update.').'</p>'
28
+));
29 29
 
30 30
 get_current_screen()->set_help_sidebar(
31
-	'<p><strong>' . __('For more information:') . '</strong></p>' .
32
-	'<p>' . __('<a href="https://codex.wordpress.org/Network_Admin_Updates_Screen" target="_blank">Documentation on Upgrade Network</a>') . '</p>' .
33
-	'<p>' . __('<a href="https://wordpress.org/support/" target="_blank">Support Forums</a>') . '</p>'
31
+	'<p><strong>'.__('For more information:').'</strong></p>'.
32
+	'<p>'.__('<a href="https://codex.wordpress.org/Network_Admin_Updates_Screen" target="_blank">Documentation on Upgrade Network</a>').'</p>'.
33
+	'<p>'.__('<a href="https://wordpress.org/support/" target="_blank">Support Forums</a>').'</p>'
34 34
 );
35 35
 
36
-require_once( ABSPATH . 'wp-admin/admin-header.php' );
36
+require_once(ABSPATH.'wp-admin/admin-header.php');
37 37
 
38
-if ( ! current_user_can( 'manage_network' ) )
39
-	wp_die( __( 'You do not have permission to access this page.' ), 403 );
38
+if ( ! current_user_can('manage_network'))
39
+	wp_die(__('You do not have permission to access this page.'), 403);
40 40
 
41 41
 echo '<div class="wrap">';
42
-echo '<h1>' . __( 'Upgrade Network' ) . '</h1>';
42
+echo '<h1>'.__('Upgrade Network').'</h1>';
43 43
 
44 44
 $action = isset($_GET['action']) ? $_GET['action'] : 'show';
45 45
 
46
-switch ( $action ) {
46
+switch ($action) {
47 47
 	case "upgrade":
48
-		$n = ( isset($_GET['n']) ) ? intval($_GET['n']) : 0;
48
+		$n = (isset($_GET['n'])) ? intval($_GET['n']) : 0;
49 49
 
50
-		if ( $n < 5 ) {
50
+		if ($n < 5) {
51 51
 			/**
52 52
 			 * @global string $wp_db_version
53 53
 			 */
54 54
 			global $wp_db_version;
55
-			update_site_option( 'wpmu_upgrade_site', $wp_db_version );
55
+			update_site_option('wpmu_upgrade_site', $wp_db_version);
56 56
 		}
57 57
 
58
-		$blogs = $wpdb->get_results( "SELECT blog_id FROM {$wpdb->blogs} WHERE site_id = '{$wpdb->siteid}' AND spam = '0' AND deleted = '0' AND archived = '0' ORDER BY registered DESC LIMIT {$n}, 5", ARRAY_A );
59
-		if ( empty( $blogs ) ) {
60
-			echo '<p>' . __( 'All done!' ) . '</p>';
58
+		$blogs = $wpdb->get_results("SELECT blog_id FROM {$wpdb->blogs} WHERE site_id = '{$wpdb->siteid}' AND spam = '0' AND deleted = '0' AND archived = '0' ORDER BY registered DESC LIMIT {$n}, 5", ARRAY_A);
59
+		if (empty($blogs)) {
60
+			echo '<p>'.__('All done!').'</p>';
61 61
 			break;
62 62
 		}
63 63
 		echo "<ul>";
64
-		foreach ( (array) $blogs as $details ) {
65
-			switch_to_blog( $details['blog_id'] );
64
+		foreach ((array) $blogs as $details) {
65
+			switch_to_blog($details['blog_id']);
66 66
 			$siteurl = site_url();
67
-			$upgrade_url = admin_url( 'upgrade.php?step=upgrade_db' );
67
+			$upgrade_url = admin_url('upgrade.php?step=upgrade_db');
68 68
 			restore_current_blog();
69 69
 
70 70
 			echo "<li>$siteurl</li>";
71 71
 
72
-			$response = wp_remote_get( $upgrade_url, array( 'timeout' => 120, 'httpversion' => '1.1' ) );
73
-			if ( is_wp_error( $response ) ) {
74
-				wp_die( sprintf(
72
+			$response = wp_remote_get($upgrade_url, array('timeout' => 120, 'httpversion' => '1.1'));
73
+			if (is_wp_error($response)) {
74
+				wp_die(sprintf(
75 75
 					/* translators: 1: site url, 2: server error message */
76
-					__( 'Warning! Problem updating %1$s. Your server may not be able to connect to sites running on it. Error message: %2$s' ),
76
+					__('Warning! Problem updating %1$s. Your server may not be able to connect to sites running on it. Error message: %2$s'),
77 77
 					$siteurl,
78
-					'<em>' . $response->get_error_message() . '</em>'
79
-				) );
78
+					'<em>'.$response->get_error_message().'</em>'
79
+				));
80 80
 			}
81 81
 
82 82
 			/**
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
 			 *
87 87
 			 * @param array|WP_Error $response The upgrade response array or WP_Error on failure.
88 88
 			 */
89
-			do_action( 'after_mu_upgrade', $response );
89
+			do_action('after_mu_upgrade', $response);
90 90
 			/**
91 91
 			 * Fires after each site has been upgraded.
92 92
 			 *
@@ -94,10 +94,10 @@  discard block
 block discarded – undo
94 94
 			 *
95 95
 			 * @param int $blog_id The Site ID.
96 96
 			 */
97
-			do_action( 'wpmu_upgrade_site', $details[ 'blog_id' ] );
97
+			do_action('wpmu_upgrade_site', $details['blog_id']);
98 98
 		}
99 99
 		echo "</ul>";
100
-		?><p><?php _e( 'If your browser doesn&#8217;t start loading the next page automatically, click this link:' ); ?> <a class="button" href="upgrade.php?action=upgrade&amp;n=<?php echo ($n + 5) ?>"><?php _e("Next Sites"); ?></a></p>
100
+		?><p><?php _e('If your browser doesn&#8217;t start loading the next page automatically, click this link:'); ?> <a class="button" href="upgrade.php?action=upgrade&amp;n=<?php echo ($n + 5) ?>"><?php _e("Next Sites"); ?></a></p>
101 101
 		<script type="text/javascript">
102 102
 		<!--
103 103
 		function nextpage() {
@@ -109,24 +109,24 @@  discard block
 block discarded – undo
109 109
 	break;
110 110
 	case 'show':
111 111
 	default:
112
-		if ( get_site_option( 'wpmu_upgrade_site' ) != $GLOBALS['wp_db_version'] ) :
112
+		if (get_site_option('wpmu_upgrade_site') != $GLOBALS['wp_db_version']) :
113 113
 		?>
114
-		<h2><?php _e( 'Database Update Required' ); ?></h2>
115
-		<p><?php _e( 'WordPress has been updated! Before we send you on your way, we need to individually upgrade the sites in your network.' ); ?></p>
114
+		<h2><?php _e('Database Update Required'); ?></h2>
115
+		<p><?php _e('WordPress has been updated! Before we send you on your way, we need to individually upgrade the sites in your network.'); ?></p>
116 116
 		<?php endif; ?>
117 117
 
118
-		<p><?php _e( 'The database update process may take a little while, so please be patient.' ); ?></p>
119
-		<p><a class="button button-primary" href="upgrade.php?action=upgrade"><?php _e( 'Upgrade Network' ); ?></a></p>
118
+		<p><?php _e('The database update process may take a little while, so please be patient.'); ?></p>
119
+		<p><a class="button button-primary" href="upgrade.php?action=upgrade"><?php _e('Upgrade Network'); ?></a></p>
120 120
 		<?php
121 121
 		/**
122 122
 		 * Fires before the footer on the network upgrade screen.
123 123
 		 *
124 124
 		 * @since MU
125 125
 		 */
126
-		do_action( 'wpmu_upgrade_page' );
126
+		do_action('wpmu_upgrade_page');
127 127
 	break;
128 128
 }
129 129
 ?>
130 130
 </div>
131 131
 
132
-<?php include( ABSPATH . 'wp-admin/admin-footer.php' ); ?>
132
+<?php include(ABSPATH.'wp-admin/admin-footer.php'); ?>
Please login to merge, or discard this patch.
src/wp-admin/network/settings.php 3 patches
Braces   +16 added lines, -10 removed lines patch added patch discarded remove patch
@@ -13,11 +13,13 @@  discard block
 block discarded – undo
13 13
 /** WordPress Translation Install API */
14 14
 require_once( ABSPATH . 'wp-admin/includes/translation-install.php' );
15 15
 
16
-if ( ! is_multisite() )
16
+if ( ! is_multisite() ) {
17 17
 	wp_die( __( 'Multisite support is not enabled.' ) );
18
+}
18 19
 
19
-if ( ! current_user_can( 'manage_network_options' ) )
20
+if ( ! current_user_can( 'manage_network_options' ) ) {
20 21
 	wp_die( __( 'You do not have permission to access this page.' ), 403 );
22
+}
21 23
 
22 24
 $title = __( 'Network Settings' );
23 25
 $parent_file = 'settings.php';
@@ -73,8 +75,9 @@  discard block
 block discarded – undo
73 75
 
74 76
 	$checked_options = array( 'menu_items' => array(), 'registrationnotification' => 'no', 'upload_space_check_disabled' => 1, 'add_new_users' => 0 );
75 77
 	foreach ( $checked_options as $option_name => $option_unchecked_value ) {
76
-		if ( ! isset( $_POST[$option_name] ) )
77
-			$_POST[$option_name] = $option_unchecked_value;
78
+		if ( ! isset( $_POST[$option_name] ) ) {
79
+					$_POST[$option_name] = $option_unchecked_value;
80
+		}
78 81
 	}
79 82
 
80 83
 	$options = array(
@@ -94,8 +97,9 @@  discard block
 block discarded – undo
94 97
 	}
95 98
 
96 99
 	foreach ( $options as $option_name ) {
97
-		if ( ! isset($_POST[$option_name]) )
98
-			continue;
100
+		if ( ! isset($_POST[$option_name]) ) {
101
+					continue;
102
+		}
99 103
 		$value = wp_unslash( $_POST[$option_name] );
100 104
 		update_site_option( $option_name, $value );
101 105
 	}
@@ -146,8 +150,9 @@  discard block
 block discarded – undo
146 150
 			<tr>
147 151
 				<th scope="row"><?php _e( 'Allow new registrations' ) ?></th>
148 152
 				<?php
149
-				if ( !get_site_option( 'registration' ) )
150
-					update_site_option( 'registration', 'none' );
153
+				if ( !get_site_option( 'registration' ) ) {
154
+									update_site_option( 'registration', 'none' );
155
+				}
151 156
 				$reg = get_site_option( 'registration' );
152 157
 				?>
153 158
 				<td>
@@ -167,8 +172,9 @@  discard block
 block discarded – undo
167 172
 			<tr>
168 173
 				<th scope="row"><?php _e( 'Registration notification' ) ?></th>
169 174
 				<?php
170
-				if ( !get_site_option( 'registrationnotification' ) )
171
-					update_site_option( 'registrationnotification', 'yes' );
175
+				if ( !get_site_option( 'registrationnotification' ) ) {
176
+									update_site_option( 'registrationnotification', 'yes' );
177
+				}
172 178
 				?>
173 179
 				<td>
174 180
 					<label><input name="registrationnotification" type="checkbox" id="registrationnotification" value="yes"<?php checked( get_site_option( 'registrationnotification' ), 'yes' ) ?> /> <?php _e( 'Send the network admin an email notification every time someone registers a site or user account.' ) ?></label>
Please login to merge, or discard this patch.
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,11 +1,11 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Multisite network settings administration panel.
4
- *
5
- * @package WordPress
6
- * @subpackage Multisite
7
- * @since 3.0.0
8
- */
3
+	 * Multisite network settings administration panel.
4
+	 *
5
+	 * @package WordPress
6
+	 * @subpackage Multisite
7
+	 * @since 3.0.0
8
+	 */
9 9
 
10 10
 require_once( dirname( __FILE__ ) . '/admin.php' );
11 11
 
Please login to merge, or discard this patch.
Spacing   +123 added lines, -123 removed lines patch added patch discarded remove patch
@@ -8,51 +8,51 @@  discard block
 block discarded – undo
8 8
  */
9 9
 
10 10
 /** Load WordPress Administration Bootstrap */
11
-require_once( dirname( __FILE__ ) . '/admin.php' );
11
+require_once(dirname(__FILE__).'/admin.php');
12 12
 
13 13
 /** WordPress Translation Install API */
14
-require_once( ABSPATH . 'wp-admin/includes/translation-install.php' );
14
+require_once(ABSPATH.'wp-admin/includes/translation-install.php');
15 15
 
16
-if ( ! is_multisite() )
17
-	wp_die( __( 'Multisite support is not enabled.' ) );
16
+if ( ! is_multisite())
17
+	wp_die(__('Multisite support is not enabled.'));
18 18
 
19
-if ( ! current_user_can( 'manage_network_options' ) )
20
-	wp_die( __( 'You do not have permission to access this page.' ), 403 );
19
+if ( ! current_user_can('manage_network_options'))
20
+	wp_die(__('You do not have permission to access this page.'), 403);
21 21
 
22
-$title = __( 'Network Settings' );
22
+$title = __('Network Settings');
23 23
 $parent_file = 'settings.php';
24 24
 
25
-add_action( 'admin_head', 'network_settings_add_js' );
25
+add_action('admin_head', 'network_settings_add_js');
26 26
 
27
-get_current_screen()->add_help_tab( array(
27
+get_current_screen()->add_help_tab(array(
28 28
 		'id'      => 'overview',
29 29
 		'title'   => __('Overview'),
30 30
 		'content' =>
31
-			'<p>' . __('This screen sets and changes options for the network as a whole. The first site is the main site in the network and network options are pulled from that original site&#8217;s options.') . '</p>' .
32
-			'<p>' . __('Operational settings has fields for the network&#8217;s name and admin email.') . '</p>' .
33
-			'<p>' . __('Registration settings can disable/enable public signups. If you let others sign up for a site, install spam plugins. Spaces, not commas, should separate names banned as sites for this network.') . '</p>' .
34
-			'<p>' . __('New site settings are defaults applied when a new site is created in the network. These include welcome email for when a new site or user account is registered, and what&#8127;s put in the first post, page, comment, comment author, and comment URL.') . '</p>' .
35
-			'<p>' . __('Upload settings control the size of the uploaded files and the amount of available upload space for each site. You can change the default value for specific sites when you edit a particular site. Allowed file types are also listed (space separated only).') . '</p>' .
36
-			'<p>' . __( 'You can set the language, and the translation files will be automatically downloaded and installed (available if your filesystem is writable).' ) . '</p>' .
37
-			'<p>' . __('Menu setting enables/disables the plugin menus from appearing for non super admins, so that only super admins, not site admins, have access to activate plugins.') . '</p>' .
38
-			'<p>' . __('Super admins can no longer be added on the Options screen. You must now go to the list of existing users on Network Admin > Users and click on Username or the Edit action link below that name. This goes to an Edit User page where you can check a box to grant super admin privileges.') . '</p>'
39
-) );
31
+			'<p>'.__('This screen sets and changes options for the network as a whole. The first site is the main site in the network and network options are pulled from that original site&#8217;s options.').'</p>'.
32
+			'<p>'.__('Operational settings has fields for the network&#8217;s name and admin email.').'</p>'.
33
+			'<p>'.__('Registration settings can disable/enable public signups. If you let others sign up for a site, install spam plugins. Spaces, not commas, should separate names banned as sites for this network.').'</p>'.
34
+			'<p>'.__('New site settings are defaults applied when a new site is created in the network. These include welcome email for when a new site or user account is registered, and what&#8127;s put in the first post, page, comment, comment author, and comment URL.').'</p>'.
35
+			'<p>'.__('Upload settings control the size of the uploaded files and the amount of available upload space for each site. You can change the default value for specific sites when you edit a particular site. Allowed file types are also listed (space separated only).').'</p>'.
36
+			'<p>'.__('You can set the language, and the translation files will be automatically downloaded and installed (available if your filesystem is writable).').'</p>'.
37
+			'<p>'.__('Menu setting enables/disables the plugin menus from appearing for non super admins, so that only super admins, not site admins, have access to activate plugins.').'</p>'.
38
+			'<p>'.__('Super admins can no longer be added on the Options screen. You must now go to the list of existing users on Network Admin > Users and click on Username or the Edit action link below that name. This goes to an Edit User page where you can check a box to grant super admin privileges.').'</p>'
39
+));
40 40
 
41 41
 get_current_screen()->set_help_sidebar(
42
-	'<p><strong>' . __('For more information:') . '</strong></p>' .
43
-	'<p>' . __('<a href="https://codex.wordpress.org/Network_Admin_Settings_Screen" target="_blank">Documentation on Network Settings</a>') . '</p>' .
44
-	'<p>' . __('<a href="https://wordpress.org/support/" target="_blank">Support Forums</a>') . '</p>'
42
+	'<p><strong>'.__('For more information:').'</strong></p>'.
43
+	'<p>'.__('<a href="https://codex.wordpress.org/Network_Admin_Settings_Screen" target="_blank">Documentation on Network Settings</a>').'</p>'.
44
+	'<p>'.__('<a href="https://wordpress.org/support/" target="_blank">Support Forums</a>').'</p>'
45 45
 );
46 46
 
47
-if ( $_POST ) {
47
+if ($_POST) {
48 48
 	/** This action is documented in wp-admin/network/edit.php */
49
-	do_action( 'wpmuadminedit' );
49
+	do_action('wpmuadminedit');
50 50
 
51
-	check_admin_referer( 'siteoptions' );
51
+	check_admin_referer('siteoptions');
52 52
 
53
-	$checked_options = array( 'menu_items' => array(), 'registrationnotification' => 'no', 'upload_space_check_disabled' => 1, 'add_new_users' => 0 );
54
-	foreach ( $checked_options as $option_name => $option_unchecked_value ) {
55
-		if ( ! isset( $_POST[$option_name] ) )
53
+	$checked_options = array('menu_items' => array(), 'registrationnotification' => 'no', 'upload_space_check_disabled' => 1, 'add_new_users' => 0);
54
+	foreach ($checked_options as $option_name => $option_unchecked_value) {
55
+		if ( ! isset($_POST[$option_name]))
56 56
 			$_POST[$option_name] = $option_unchecked_value;
57 57
 	}
58 58
 
@@ -65,18 +65,18 @@  discard block
 block discarded – undo
65 65
 	);
66 66
 
67 67
 	// Handle translation install.
68
-	if ( ! empty( $_POST['WPLANG'] ) && wp_can_install_language_pack() ) {  // @todo: Skip if already installed
69
-		$language = wp_download_language_pack( $_POST['WPLANG'] );
70
-		if ( $language ) {
68
+	if ( ! empty($_POST['WPLANG']) && wp_can_install_language_pack()) {  // @todo: Skip if already installed
69
+		$language = wp_download_language_pack($_POST['WPLANG']);
70
+		if ($language) {
71 71
 			$_POST['WPLANG'] = $language;
72 72
 		}
73 73
 	}
74 74
 
75
-	foreach ( $options as $option_name ) {
76
-		if ( ! isset($_POST[$option_name]) )
75
+	foreach ($options as $option_name) {
76
+		if ( ! isset($_POST[$option_name]))
77 77
 			continue;
78
-		$value = wp_unslash( $_POST[$option_name] );
79
-		update_site_option( $option_name, $value );
78
+		$value = wp_unslash($_POST[$option_name]);
79
+		update_site_option($option_name, $value);
80 80
 	}
81 81
 
82 82
 	/**
@@ -84,62 +84,62 @@  discard block
 block discarded – undo
84 84
 	 *
85 85
 	 * @since MU
86 86
 	 */
87
-	do_action( 'update_wpmu_options' );
87
+	do_action('update_wpmu_options');
88 88
 
89
-	wp_redirect( add_query_arg( 'updated', 'true', network_admin_url( 'settings.php' ) ) );
89
+	wp_redirect(add_query_arg('updated', 'true', network_admin_url('settings.php')));
90 90
 	exit();
91 91
 }
92 92
 
93
-include( ABSPATH . 'wp-admin/admin-header.php' );
93
+include(ABSPATH.'wp-admin/admin-header.php');
94 94
 
95
-if ( isset( $_GET['updated'] ) ) {
96
-	?><div id="message" class="updated notice is-dismissible"><p><?php _e( 'Options saved.' ) ?></p></div><?php
95
+if (isset($_GET['updated'])) {
96
+	?><div id="message" class="updated notice is-dismissible"><p><?php _e('Options saved.') ?></p></div><?php
97 97
 }
98 98
 ?>
99 99
 
100 100
 <div class="wrap">
101
-	<h1><?php echo esc_html( $title ); ?></h1>
101
+	<h1><?php echo esc_html($title); ?></h1>
102 102
 	<form method="post" action="settings.php" novalidate="novalidate">
103
-		<?php wp_nonce_field( 'siteoptions' ); ?>
104
-		<h2><?php _e( 'Operational Settings' ); ?></h2>
103
+		<?php wp_nonce_field('siteoptions'); ?>
104
+		<h2><?php _e('Operational Settings'); ?></h2>
105 105
 		<table class="form-table">
106 106
 			<tr>
107
-				<th scope="row"><label for="site_name"><?php _e( 'Network Title' ) ?></label></th>
107
+				<th scope="row"><label for="site_name"><?php _e('Network Title') ?></label></th>
108 108
 				<td>
109
-					<input name="site_name" type="text" id="site_name" class="regular-text" value="<?php echo esc_attr( $current_site->site_name ) ?>" />
109
+					<input name="site_name" type="text" id="site_name" class="regular-text" value="<?php echo esc_attr($current_site->site_name) ?>" />
110 110
 				</td>
111 111
 			</tr>
112 112
 
113 113
 			<tr>
114
-				<th scope="row"><label for="admin_email"><?php _e( 'Network Admin Email' ) ?></label></th>
114
+				<th scope="row"><label for="admin_email"><?php _e('Network Admin Email') ?></label></th>
115 115
 				<td>
116
-					<input name="admin_email" type="email" id="admin_email" aria-describedby="admin-email-desc" class="regular-text" value="<?php echo esc_attr( get_site_option( 'admin_email' ) ) ?>" />
116
+					<input name="admin_email" type="email" id="admin_email" aria-describedby="admin-email-desc" class="regular-text" value="<?php echo esc_attr(get_site_option('admin_email')) ?>" />
117 117
 					<p class="description" id="admin-email-desc">
118
-						<?php _e( 'This email address will receive notifications. Registration and support emails will also come from this address.' ); ?>
118
+						<?php _e('This email address will receive notifications. Registration and support emails will also come from this address.'); ?>
119 119
 					</p>
120 120
 				</td>
121 121
 			</tr>
122 122
 		</table>
123
-		<h2><?php _e( 'Registration Settings' ); ?></h2>
123
+		<h2><?php _e('Registration Settings'); ?></h2>
124 124
 		<table class="form-table">
125 125
 			<tr>
126
-				<th scope="row"><?php _e( 'Allow new registrations' ) ?></th>
126
+				<th scope="row"><?php _e('Allow new registrations') ?></th>
127 127
 				<?php
128
-				if ( !get_site_option( 'registration' ) )
129
-					update_site_option( 'registration', 'none' );
130
-				$reg = get_site_option( 'registration' );
128
+				if ( ! get_site_option('registration'))
129
+					update_site_option('registration', 'none');
130
+				$reg = get_site_option('registration');
131 131
 				?>
132 132
 				<td>
133 133
 					<fieldset>
134
-					<legend class="screen-reader-text"><?php _e( 'New registrations settings' ) ?></legend>
135
-					<label><input name="registration" type="radio" id="registration1" value="none"<?php checked( $reg, 'none') ?> /> <?php _e( 'Registration is disabled.' ); ?></label><br />
136
-					<label><input name="registration" type="radio" id="registration2" value="user"<?php checked( $reg, 'user') ?> /> <?php _e( 'User accounts may be registered.' ); ?></label><br />
137
-					<label><input name="registration" type="radio" id="registration3" value="blog"<?php checked( $reg, 'blog') ?> /> <?php _e( 'Logged in users may register new sites.' ); ?></label><br />
138
-					<label><input name="registration" type="radio" id="registration4" value="all"<?php checked( $reg, 'all') ?> /> <?php _e( 'Both sites and user accounts can be registered.' ); ?></label>
139
-					<?php if ( is_subdomain_install() ) {
134
+					<legend class="screen-reader-text"><?php _e('New registrations settings') ?></legend>
135
+					<label><input name="registration" type="radio" id="registration1" value="none"<?php checked($reg, 'none') ?> /> <?php _e('Registration is disabled.'); ?></label><br />
136
+					<label><input name="registration" type="radio" id="registration2" value="user"<?php checked($reg, 'user') ?> /> <?php _e('User accounts may be registered.'); ?></label><br />
137
+					<label><input name="registration" type="radio" id="registration3" value="blog"<?php checked($reg, 'blog') ?> /> <?php _e('Logged in users may register new sites.'); ?></label><br />
138
+					<label><input name="registration" type="radio" id="registration4" value="all"<?php checked($reg, 'all') ?> /> <?php _e('Both sites and user accounts can be registered.'); ?></label>
139
+					<?php if (is_subdomain_install()) {
140 140
 						echo '<p class="description">';
141 141
 						/* translators: 1: NOBLOGREDIRECT 2: wp-config.php */
142
-						printf( __( 'If registration is disabled, please set %1$s in %2$s to a URL you will redirect visitors to if they visit a non-existent site.' ),
142
+						printf(__('If registration is disabled, please set %1$s in %2$s to a URL you will redirect visitors to if they visit a non-existent site.'),
143 143
 							'<code>NOBLOGREDIRECT</code>',
144 144
 							'<code>wp-config.php</code>'
145 145
 						);
@@ -150,42 +150,42 @@  discard block
 block discarded – undo
150 150
 			</tr>
151 151
 
152 152
 			<tr>
153
-				<th scope="row"><?php _e( 'Registration notification' ) ?></th>
153
+				<th scope="row"><?php _e('Registration notification') ?></th>
154 154
 				<?php
155
-				if ( !get_site_option( 'registrationnotification' ) )
156
-					update_site_option( 'registrationnotification', 'yes' );
155
+				if ( ! get_site_option('registrationnotification'))
156
+					update_site_option('registrationnotification', 'yes');
157 157
 				?>
158 158
 				<td>
159
-					<label><input name="registrationnotification" type="checkbox" id="registrationnotification" value="yes"<?php checked( get_site_option( 'registrationnotification' ), 'yes' ) ?> /> <?php _e( 'Send the network admin an email notification every time someone registers a site or user account.' ) ?></label>
159
+					<label><input name="registrationnotification" type="checkbox" id="registrationnotification" value="yes"<?php checked(get_site_option('registrationnotification'), 'yes') ?> /> <?php _e('Send the network admin an email notification every time someone registers a site or user account.') ?></label>
160 160
 				</td>
161 161
 			</tr>
162 162
 
163 163
 			<tr id="addnewusers">
164
-				<th scope="row"><?php _e( 'Add New Users' ) ?></th>
164
+				<th scope="row"><?php _e('Add New Users') ?></th>
165 165
 				<td>
166
-					<label><input name="add_new_users" type="checkbox" id="add_new_users" value="1"<?php checked( get_site_option( 'add_new_users' ) ) ?> /> <?php _e( 'Allow site administrators to add new users to their site via the "Users &rarr; Add New" page.' ); ?></label>
166
+					<label><input name="add_new_users" type="checkbox" id="add_new_users" value="1"<?php checked(get_site_option('add_new_users')) ?> /> <?php _e('Allow site administrators to add new users to their site via the "Users &rarr; Add New" page.'); ?></label>
167 167
 				</td>
168 168
 			</tr>
169 169
 
170 170
 			<tr>
171
-				<th scope="row"><label for="illegal_names"><?php _e( 'Banned Names' ) ?></label></th>
171
+				<th scope="row"><label for="illegal_names"><?php _e('Banned Names') ?></label></th>
172 172
 				<td>
173
-					<input name="illegal_names" type="text" id="illegal_names" aria-describedby="illegal-names-desc" class="large-text" value="<?php echo esc_attr( implode( " ", (array) get_site_option( 'illegal_names' ) ) ); ?>" size="45" />
173
+					<input name="illegal_names" type="text" id="illegal_names" aria-describedby="illegal-names-desc" class="large-text" value="<?php echo esc_attr(implode(" ", (array) get_site_option('illegal_names'))); ?>" size="45" />
174 174
 					<p class="description" id="illegal-names-desc">
175
-						<?php _e( 'Users are not allowed to register these sites. Separate names by spaces.' ) ?>
175
+						<?php _e('Users are not allowed to register these sites. Separate names by spaces.') ?>
176 176
 					</p>
177 177
 				</td>
178 178
 			</tr>
179 179
 
180 180
 			<tr>
181
-				<th scope="row"><label for="limited_email_domains"><?php _e( 'Limited Email Registrations' ) ?></label></th>
181
+				<th scope="row"><label for="limited_email_domains"><?php _e('Limited Email Registrations') ?></label></th>
182 182
 				<td>
183
-					<?php $limited_email_domains = get_site_option( 'limited_email_domains' );
184
-					$limited_email_domains = str_replace( ' ', "\n", $limited_email_domains ); ?>
183
+					<?php $limited_email_domains = get_site_option('limited_email_domains');
184
+					$limited_email_domains = str_replace(' ', "\n", $limited_email_domains); ?>
185 185
 					<textarea name="limited_email_domains" id="limited_email_domains" aria-describedby="limited-email-domains-desc" cols="45" rows="5">
186
-<?php echo esc_textarea( $limited_email_domains == '' ? '' : implode( "\n", (array) $limited_email_domains ) ); ?></textarea>
186
+<?php echo esc_textarea($limited_email_domains == '' ? '' : implode("\n", (array) $limited_email_domains)); ?></textarea>
187 187
 					<p class="description" id="limited-email-domains-desc">
188
-						<?php _e( 'If you want to limit site registrations to certain domains. One domain per line.' ) ?>
188
+						<?php _e('If you want to limit site registrations to certain domains. One domain per line.') ?>
189 189
 					</p>
190 190
 				</td>
191 191
 			</tr>
@@ -194,114 +194,114 @@  discard block
 block discarded – undo
194 194
 				<th scope="row"><label for="banned_email_domains"><?php _e('Banned Email Domains') ?></label></th>
195 195
 				<td>
196 196
 					<textarea name="banned_email_domains" id="banned_email_domains" aria-describedby="banned-email-domains-desc" cols="45" rows="5">
197
-<?php echo esc_textarea( get_site_option( 'banned_email_domains' ) == '' ? '' : implode( "\n", (array) get_site_option( 'banned_email_domains' ) ) ); ?></textarea>
197
+<?php echo esc_textarea(get_site_option('banned_email_domains') == '' ? '' : implode("\n", (array) get_site_option('banned_email_domains'))); ?></textarea>
198 198
 					<p class="description" id="banned-email-domains-desc">
199
-						<?php _e( 'If you want to ban domains from site registrations. One domain per line.' ) ?>
199
+						<?php _e('If you want to ban domains from site registrations. One domain per line.') ?>
200 200
 					</p>
201 201
 				</td>
202 202
 			</tr>
203 203
 
204 204
 		</table>
205
-		<h2><?php _e( 'New Site Settings' ); ?></h2>
205
+		<h2><?php _e('New Site Settings'); ?></h2>
206 206
 		<table class="form-table">
207 207
 
208 208
 			<tr>
209
-				<th scope="row"><label for="welcome_email"><?php _e( 'Welcome Email' ) ?></label></th>
209
+				<th scope="row"><label for="welcome_email"><?php _e('Welcome Email') ?></label></th>
210 210
 				<td>
211 211
 					<textarea name="welcome_email" id="welcome_email" aria-describedby="welcome-email-desc" rows="5" cols="45" class="large-text">
212
-<?php echo esc_textarea( get_site_option( 'welcome_email' ) ) ?></textarea>
212
+<?php echo esc_textarea(get_site_option('welcome_email')) ?></textarea>
213 213
 					<p class="description" id="welcome-email-desc">
214
-						<?php _e( 'The welcome email sent to new site owners.' ) ?>
214
+						<?php _e('The welcome email sent to new site owners.') ?>
215 215
 					</p>
216 216
 				</td>
217 217
 			</tr>
218 218
 			<tr>
219
-				<th scope="row"><label for="welcome_user_email"><?php _e( 'Welcome User Email' ) ?></label></th>
219
+				<th scope="row"><label for="welcome_user_email"><?php _e('Welcome User Email') ?></label></th>
220 220
 				<td>
221 221
 					<textarea name="welcome_user_email" id="welcome_user_email" aria-describedby="welcome-user-email-desc" rows="5" cols="45" class="large-text">
222
-<?php echo esc_textarea( get_site_option( 'welcome_user_email' ) ) ?></textarea>
222
+<?php echo esc_textarea(get_site_option('welcome_user_email')) ?></textarea>
223 223
 					<p class="description" id="welcome-user-email-desc">
224
-						<?php _e( 'The welcome email sent to new users.' ) ?>
224
+						<?php _e('The welcome email sent to new users.') ?>
225 225
 					</p>
226 226
 				</td>
227 227
 			</tr>
228 228
 			<tr>
229
-				<th scope="row"><label for="first_post"><?php _e( 'First Post' ) ?></label></th>
229
+				<th scope="row"><label for="first_post"><?php _e('First Post') ?></label></th>
230 230
 				<td>
231 231
 					<textarea name="first_post" id="first_post" aria-describedby="first-post-desc" rows="5" cols="45" class="large-text">
232
-<?php echo esc_textarea( get_site_option( 'first_post' ) ) ?></textarea>
232
+<?php echo esc_textarea(get_site_option('first_post')) ?></textarea>
233 233
 					<p class="description" id="first-post-desc">
234
-						<?php _e( 'The first post on a new site.' ) ?>
234
+						<?php _e('The first post on a new site.') ?>
235 235
 					</p>
236 236
 				</td>
237 237
 			</tr>
238 238
 			<tr>
239
-				<th scope="row"><label for="first_page"><?php _e( 'First Page' ) ?></label></th>
239
+				<th scope="row"><label for="first_page"><?php _e('First Page') ?></label></th>
240 240
 				<td>
241 241
 					<textarea name="first_page" id="first_page" aria-describedby="first-page-desc" rows="5" cols="45" class="large-text">
242
-<?php echo esc_textarea( get_site_option( 'first_page' ) ) ?></textarea>
242
+<?php echo esc_textarea(get_site_option('first_page')) ?></textarea>
243 243
 					<p class="description" id="first-page-desc">
244
-						<?php _e( 'The first page on a new site.' ) ?>
244
+						<?php _e('The first page on a new site.') ?>
245 245
 					</p>
246 246
 				</td>
247 247
 			</tr>
248 248
 			<tr>
249
-				<th scope="row"><label for="first_comment"><?php _e( 'First Comment' ) ?></label></th>
249
+				<th scope="row"><label for="first_comment"><?php _e('First Comment') ?></label></th>
250 250
 				<td>
251 251
 					<textarea name="first_comment" id="first_comment" aria-describedby="first-comment-desc" rows="5" cols="45" class="large-text">
252
-<?php echo esc_textarea( get_site_option( 'first_comment' ) ) ?></textarea>
252
+<?php echo esc_textarea(get_site_option('first_comment')) ?></textarea>
253 253
 					<p class="description" id="first-comment-desc">
254
-						<?php _e( 'The first comment on a new site.' ) ?>
254
+						<?php _e('The first comment on a new site.') ?>
255 255
 					</p>
256 256
 				</td>
257 257
 			</tr>
258 258
 			<tr>
259
-				<th scope="row"><label for="first_comment_author"><?php _e( 'First Comment Author' ) ?></label></th>
259
+				<th scope="row"><label for="first_comment_author"><?php _e('First Comment Author') ?></label></th>
260 260
 				<td>
261 261
 					<input type="text" size="40" name="first_comment_author" id="first_comment_author" aria-describedby="first-comment-author-desc" value="<?php echo get_site_option('first_comment_author') ?>" />
262 262
 					<p class="description" id="first-comment-author-desc">
263
-						<?php _e( 'The author of the first comment on a new site.' ) ?>
263
+						<?php _e('The author of the first comment on a new site.') ?>
264 264
 					</p>
265 265
 				</td>
266 266
 			</tr>
267 267
 			<tr>
268
-				<th scope="row"><label for="first_comment_url"><?php _e( 'First Comment URL' ) ?></label></th>
268
+				<th scope="row"><label for="first_comment_url"><?php _e('First Comment URL') ?></label></th>
269 269
 				<td>
270
-					<input type="text" size="40" name="first_comment_url" id="first_comment_url" aria-describedby="first-comment-url-desc" value="<?php echo esc_attr( get_site_option( 'first_comment_url' ) ) ?>" />
270
+					<input type="text" size="40" name="first_comment_url" id="first_comment_url" aria-describedby="first-comment-url-desc" value="<?php echo esc_attr(get_site_option('first_comment_url')) ?>" />
271 271
 					<p class="description" id="first-comment-url-desc">
272
-						<?php _e( 'The URL for the first comment on a new site.' ) ?>
272
+						<?php _e('The URL for the first comment on a new site.') ?>
273 273
 					</p>
274 274
 				</td>
275 275
 			</tr>
276 276
 		</table>
277
-		<h2><?php _e( 'Upload Settings' ); ?></h2>
277
+		<h2><?php _e('Upload Settings'); ?></h2>
278 278
 		<table class="form-table">
279 279
 			<tr>
280
-				<th scope="row"><?php _e( 'Site upload space' ) ?></th>
280
+				<th scope="row"><?php _e('Site upload space') ?></th>
281 281
 				<td>
282
-					<label><input type="checkbox" id="upload_space_check_disabled" name="upload_space_check_disabled" value="0"<?php checked( (bool) get_site_option( 'upload_space_check_disabled' ), false ) ?>/> <?php printf( __( 'Limit total size of files uploaded to %s MB' ), '</label><label><input name="blog_upload_space" type="number" min="0" style="width: 100px" id="blog_upload_space" aria-describedby="blog-upload-space-desc" value="' . esc_attr( get_site_option('blog_upload_space', 100) ) . '" />' ); ?></label><br />
282
+					<label><input type="checkbox" id="upload_space_check_disabled" name="upload_space_check_disabled" value="0"<?php checked((bool) get_site_option('upload_space_check_disabled'), false) ?>/> <?php printf(__('Limit total size of files uploaded to %s MB'), '</label><label><input name="blog_upload_space" type="number" min="0" style="width: 100px" id="blog_upload_space" aria-describedby="blog-upload-space-desc" value="'.esc_attr(get_site_option('blog_upload_space', 100)).'" />'); ?></label><br />
283 283
 					<p class="screen-reader-text" id="blog-upload-space-desc">
284
-						<?php _e( 'Size in megabytes' ) ?>
284
+						<?php _e('Size in megabytes') ?>
285 285
 					</p>
286 286
 				</td>
287 287
 			</tr>
288 288
 
289 289
 			<tr>
290
-				<th scope="row"><label for="upload_filetypes"><?php _e( 'Upload file types' ) ?></label></th>
290
+				<th scope="row"><label for="upload_filetypes"><?php _e('Upload file types') ?></label></th>
291 291
 				<td>
292
-					<input name="upload_filetypes" type="text" id="upload_filetypes" aria-describedby="upload-filetypes-desc" class="large-text" value="<?php echo esc_attr( get_site_option( 'upload_filetypes', 'jpg jpeg png gif' ) ) ?>" size="45" />
292
+					<input name="upload_filetypes" type="text" id="upload_filetypes" aria-describedby="upload-filetypes-desc" class="large-text" value="<?php echo esc_attr(get_site_option('upload_filetypes', 'jpg jpeg png gif')) ?>" size="45" />
293 293
 					<p class="description" id="upload-filetypes-desc">
294
-						<?php _e( 'Allowed file types. Separate types by spaces.' ) ?>
294
+						<?php _e('Allowed file types. Separate types by spaces.') ?>
295 295
 					</p>
296 296
 				</td>
297 297
 			</tr>
298 298
 
299 299
 			<tr>
300
-				<th scope="row"><label for="fileupload_maxk"><?php _e( 'Max upload file size' ) ?></label></th>
300
+				<th scope="row"><label for="fileupload_maxk"><?php _e('Max upload file size') ?></label></th>
301 301
 				<td>
302
-					<?php printf( _x( '%s KB', 'File size in kilobytes' ), '<input name="fileupload_maxk" type="number" min="0" style="width: 100px" id="fileupload_maxk" aria-describedby="fileupload-maxk-desc" value="' . esc_attr( get_site_option( 'fileupload_maxk', 300 ) ) . '" />' ); ?>
302
+					<?php printf(_x('%s KB', 'File size in kilobytes'), '<input name="fileupload_maxk" type="number" min="0" style="width: 100px" id="fileupload_maxk" aria-describedby="fileupload-maxk-desc" value="'.esc_attr(get_site_option('fileupload_maxk', 300)).'" />'); ?>
303 303
 					<p class="screen-reader-text" id="fileupload-maxk-desc">
304
-						<?php _e( 'Size in kilobytes' ) ?>
304
+						<?php _e('Size in kilobytes') ?>
305 305
 					</p>
306 306
 				</td>
307 307
 			</tr>
@@ -310,27 +310,27 @@  discard block
 block discarded – undo
310 310
 		<?php
311 311
 		$languages = get_available_languages();
312 312
 		$translations = wp_get_available_translations();
313
-		if ( ! empty( $languages ) || ! empty( $translations ) ) {
313
+		if ( ! empty($languages) || ! empty($translations)) {
314 314
 			?>
315
-			<h2><?php _e( 'Language Settings' ); ?></h2>
315
+			<h2><?php _e('Language Settings'); ?></h2>
316 316
 			<table class="form-table">
317 317
 				<tr>
318
-					<th><label for="WPLANG"><?php _e( 'Default Language' ); ?></label></th>
318
+					<th><label for="WPLANG"><?php _e('Default Language'); ?></label></th>
319 319
 					<td>
320 320
 						<?php
321
-						$lang = get_site_option( 'WPLANG' );
322
-						if ( ! in_array( $lang, $languages ) ) {
321
+						$lang = get_site_option('WPLANG');
322
+						if ( ! in_array($lang, $languages)) {
323 323
 							$lang = '';
324 324
 						}
325 325
 
326
-						wp_dropdown_languages( array(
326
+						wp_dropdown_languages(array(
327 327
 							'name'         => 'WPLANG',
328 328
 							'id'           => 'WPLANG',
329 329
 							'selected'     => $lang,
330 330
 							'languages'    => $languages,
331 331
 							'translations' => $translations,
332 332
 							'show_available_translations' => wp_can_install_language_pack(),
333
-						) );
333
+						));
334 334
 						?>
335 335
 					</td>
336 336
 				</tr>
@@ -339,13 +339,13 @@  discard block
 block discarded – undo
339 339
 		}
340 340
 		?>
341 341
 
342
-		<h2><?php _e( 'Menu Settings' ); ?></h2>
342
+		<h2><?php _e('Menu Settings'); ?></h2>
343 343
 		<table id="menu" class="form-table">
344 344
 			<tr>
345
-				<th scope="row"><?php _e( 'Enable administration menus' ); ?></th>
345
+				<th scope="row"><?php _e('Enable administration menus'); ?></th>
346 346
 				<td>
347 347
 			<?php
348
-			$menu_perms = get_site_option( 'menu_items' );
348
+			$menu_perms = get_site_option('menu_items');
349 349
 			/**
350 350
 			 * Filter available network-wide administration menu options.
351 351
 			 *
@@ -361,14 +361,14 @@  discard block
 block discarded – undo
361 361
 			 *
362 362
 			 * @param array $admin_menus The menu items available.
363 363
 			 */
364
-			$menu_items = apply_filters( 'mu_menu_items', array( 'plugins' => __( 'Plugins' ) ) );
364
+			$menu_items = apply_filters('mu_menu_items', array('plugins' => __('Plugins')));
365 365
 			$fieldset_end = '';
366
-			if ( count( (array) $menu_items ) > 1 ) {
367
-				echo '<fieldset><legend class="screen-reader-text">' . __( 'Enable menus' ) . '</legend>';
366
+			if (count((array) $menu_items) > 1) {
367
+				echo '<fieldset><legend class="screen-reader-text">'.__('Enable menus').'</legend>';
368 368
 				$fieldset_end = '</fieldset>';
369 369
 			}
370
-			foreach ( (array) $menu_items as $key => $val ) {
371
-				echo "<label><input type='checkbox' name='menu_items[" . $key . "]' value='1'" . ( isset( $menu_perms[$key] ) ? checked( $menu_perms[$key], '1', false ) : '' ) . " /> " . esc_html( $val ) . "</label><br/>";
370
+			foreach ((array) $menu_items as $key => $val) {
371
+				echo "<label><input type='checkbox' name='menu_items[".$key."]' value='1'".(isset($menu_perms[$key]) ? checked($menu_perms[$key], '1', false) : '')." /> ".esc_html($val)."</label><br/>";
372 372
 			}
373 373
 			echo $fieldset_end;
374 374
 			?>
@@ -382,9 +382,9 @@  discard block
 block discarded – undo
382 382
 		 *
383 383
 		 * @since MU
384 384
 		 */
385
-		do_action( 'wpmu_options' ); ?>
385
+		do_action('wpmu_options'); ?>
386 386
 		<?php submit_button(); ?>
387 387
 	</form>
388 388
 </div>
389 389
 
390
-<?php include( ABSPATH . 'wp-admin/admin-footer.php' ); ?>
390
+<?php include(ABSPATH.'wp-admin/admin-footer.php'); ?>
Please login to merge, or discard this patch.