~canonical-sysadmins/wordpress/4.8.1

« back to all changes in this revision

Viewing changes to wp-admin/network/site-themes.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:
14
14
        wp_die( __( 'Multisite support is not enabled.' ) );
15
15
 
16
16
if ( ! current_user_can( 'manage_sites' ) )
17
 
        wp_die( __( 'You do not have sufficient permissions to manage themes for this site.' ) );
 
17
        wp_die( __( 'Sorry, you are not allowed to manage themes for this site.' ) );
18
18
 
19
19
get_current_screen()->add_help_tab( array(
20
20
        'id'      => 'overview',
67
67
}
68
68
 
69
69
if ( !can_edit_network( $details->site_id ) )
70
 
        wp_die( __( 'You do not have permission to access this page.' ), 403 );
 
70
        wp_die( __( 'Sorry, you are not allowed to access this page.' ), 403 );
71
71
 
72
72
$is_main_site = is_main_site( $id );
73
73
 
149
149
<div class="wrap">
150
150
<h1 id="edit-site"><?php echo $title; ?></h1>
151
151
<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>
152
 
<h2 class="nav-tab-wrapper nav-tab-small wp-clearfix">
153
152
<?php
154
 
$tabs = array(
155
 
        'site-info'     => array( 'label' => __( 'Info' ),     'url' => 'site-info.php'     ),
156
 
        'site-users'    => array( 'label' => __( 'Users' ),    'url' => 'site-users.php'    ),
157
 
        'site-themes'   => array( 'label' => __( 'Themes' ),   'url' => 'site-themes.php'   ),
158
 
        'site-settings' => array( 'label' => __( 'Settings' ), 'url' => 'site-settings.php' ),
159
 
);
160
 
foreach ( $tabs as $tab_id => $tab ) {
161
 
        $class = ( $tab['url'] == $pagenow ) ? ' nav-tab-active' : '';
162
 
        echo '<a href="' . $tab['url'] . '?id=' . $id .'" class="nav-tab' . $class . '">' . esc_html( $tab['label'] ) . '</a>';
163
 
}
164
 
?>
165
 
</h2><?php
 
153
 
 
154
network_edit_site_nav( array(
 
155
        'blog_id'  => $id,
 
156
        'selected' => 'site-themes'
 
157
) );
166
158
 
167
159
if ( isset( $_GET['enabled'] ) ) {
168
160
        $enabled = absint( $_GET['enabled'] );