~canonical-sysadmins/wordpress/4.8.1

« back to all changes in this revision

Viewing changes to wp-admin/network/site-info.php

  • Committer: Barry Price
  • Date: 2016-08-17 04:50:12 UTC
  • mfrom: (1.1.18 upstream)
  • Revision ID: barry.price@canonical.com-20160817045012-qfui81zhqnqv2ba9
Merge WP4.6 from upstream

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
}
16
16
 
17
17
if ( ! current_user_can( 'manage_sites' ) ) {
18
 
        wp_die( __( 'You do not have sufficient permissions to edit this site.' ) );
 
18
        wp_die( __( 'Sorry, you are not allowed to edit this site.' ) );
19
19
}
20
20
 
21
21
get_current_screen()->add_help_tab( array(
47
47
}
48
48
 
49
49
if ( ! can_edit_network( $details->site_id ) ) {
50
 
        wp_die( __( 'You do not have permission to access this page.' ), 403 );
 
50
        wp_die( __( 'Sorry, you are not allowed to access this page.' ), 403 );
51
51
}
52
52
 
53
53
$parsed_scheme = parse_url( $details->siteurl, PHP_URL_SCHEME );
143
143
<div class="wrap">
144
144
<h1 id="edit-site"><?php echo $title; ?></h1>
145
145
<p class="edit-site-actions"><a href="<?php echo esc_url( get_home_url( $id, '/' ) ); ?>"><?php _e( 'Visit' ); ?></a> | <a href="<?php echo esc_url( get_admin_url( $id ) ); ?>"><?php _e( 'Dashboard' ); ?></a></p>
146
 
<h2 class="nav-tab-wrapper nav-tab-small wp-clearfix">
147
 
<?php
148
 
$tabs = array(
149
 
        'site-info'     => array( 'label' => __( 'Info' ),     'url' => 'site-info.php'     ),
150
 
        'site-users'    => array( 'label' => __( 'Users' ),    'url' => 'site-users.php'    ),
151
 
        'site-themes'   => array( 'label' => __( 'Themes' ),   'url' => 'site-themes.php'   ),
152
 
        'site-settings' => array( 'label' => __( 'Settings' ), 'url' => 'site-settings.php' ),
153
 
);
154
 
foreach ( $tabs as $tab_id => $tab ) {
155
 
        $class = ( $tab['url'] == $pagenow ) ? ' nav-tab-active' : '';
156
 
        echo '<a href="' . $tab['url'] . '?id=' . $id .'" class="nav-tab' . $class . '">' . esc_html( $tab['label'] ) . '</a>';
157
 
}
158
 
?>
159
 
</h2>
160
 
<?php
 
146
<?php
 
147
 
 
148
network_edit_site_nav( array(
 
149
        'blog_id'  => $id,
 
150
        'selected' => 'site-info'
 
151
) );
 
152
 
161
153
if ( ! empty( $messages ) ) {
162
154
        foreach ( $messages as $msg ) {
163
155
                echo '<div id="message" class="updated notice is-dismissible"><p>' . $msg . '</p></div>';