Update WP and plugins

This commit is contained in:
Oliver Davies 2019-04-16 20:56:22 +01:00
parent 10a4713229
commit 1fb77fc4ff
864 changed files with 101724 additions and 78262 deletions

View file

@ -9,11 +9,13 @@
require_once( dirname( __FILE__ ) . '/admin.php' );
if ( !is_multisite() )
if ( ! is_multisite() ) {
wp_die( __( 'Multisite support is not enabled.' ) );
}
if ( ! current_user_can('read') )
if ( ! current_user_can( 'read' ) ) {
wp_die( __( 'Sorry, you are not allowed to access this page.' ) );
}
$action = isset( $_POST['action'] ) ? $_POST['action'] : 'splash';
@ -32,20 +34,22 @@ if ( 'updateblogsettings' == $action && isset( $_POST['primary_blog'] ) ) {
}
}
$title = __( 'My Sites' );
$title = __( 'My Sites' );
$parent_file = 'index.php';
get_current_screen()->add_help_tab( array(
'id' => 'overview',
'title' => __('Overview'),
'content' =>
'<p>' . __('This screen shows an individual user all of their sites in this network, and also allows that user to set a primary site. They can use the links under each site to visit either the front end or the dashboard for that site.') . '</p>'
) );
get_current_screen()->add_help_tab(
array(
'id' => 'overview',
'title' => __( 'Overview' ),
'content' =>
'<p>' . __( 'This screen shows an individual user all of their sites in this network, and also allows that user to set a primary site. They can use the links under each site to visit either the front end or the dashboard for that site.' ) . '</p>',
)
);
get_current_screen()->set_help_sidebar(
'<p><strong>' . __('For more information:') . '</strong></p>' .
'<p>' . __('<a href="https://codex.wordpress.org/Dashboard_My_Sites_Screen">Documentation on My Sites</a>') . '</p>' .
'<p>' . __('<a href="https://wordpress.org/support/">Support Forums</a>') . '</p>'
'<p><strong>' . __( 'For more information:' ) . '</strong></p>' .
'<p>' . __( '<a href="https://codex.wordpress.org/Dashboard_My_Sites_Screen">Documentation on My Sites</a>' ) . '</p>' .
'<p>' . __( '<a href="https://wordpress.org/support/">Support Forums</a>' ) . '</p>'
);
require_once( ABSPATH . 'wp-admin/admin-header.php' );
@ -55,9 +59,11 @@ if ( $updated ) { ?>
<?php } ?>
<div class="wrap">
<h1 class="wp-heading-inline"><?php
<h1 class="wp-heading-inline">
<?php
echo esc_html( $title );
?></h1>
?>
</h1>
<?php
if ( in_array( get_site_option( 'registration' ), array( 'all', 'blog' ) ) ) {
@ -71,7 +77,7 @@ if ( empty( $blogs ) ) :
_e( 'You must be a member of at least one site to use this page.' );
echo '</p>';
else :
?>
?>
<hr class="wp-header-end">
@ -110,10 +116,10 @@ else :
foreach ( $blogs as $user_blog ) {
switch_to_blog( $user_blog->userblog_id );
echo "<li>";
echo '<li>';
echo "<h3>{$user_blog->blogname}</h3>";
$actions = "<a href='" . esc_url( home_url() ). "'>" . __( 'Visit' ) . '</a>';
$actions = "<a href='" . esc_url( home_url() ) . "'>" . __( 'Visit' ) . '</a>';
if ( current_user_can( 'read' ) ) {
$actions .= " | <a href='" . esc_url( admin_url() ) . "'>" . __( 'Dashboard' ) . '</a>';
@ -132,14 +138,17 @@ else :
/** This filter is documented in wp-admin/my-sites.php */
echo apply_filters( 'myblogs_options', '', $user_blog );
echo "</li>";
echo '</li>';
restore_current_blog();
}?>
}
?>
</ul>
<?php
if ( count( $blogs ) > 1 || has_action( 'myblogs_allblogs_options' ) || has_filter( 'myblogs_options' ) ) {
?><input type="hidden" name="action" value="updateblogsettings" /><?php
?>
<input type="hidden" name="action" value="updateblogsettings" />
<?php
wp_nonce_field( 'update-my-sites' );
submit_button();
}