From 4d9d985a64b9d34bcb69f8b4204e8a3d91219c40 Mon Sep 17 00:00:00 2001 From: Drew Jaynes Date: Sat, 26 Oct 2013 20:32:14 +0000 Subject: [PATCH] Inline documentation for hooks in wp-admin/network/site-users.php. Props sboisvert for the initial patch. Props kpdesign. Fixes #25497. git-svn-id: https://develop.svn.wordpress.org/trunk@25939 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/network/site-users.php | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/src/wp-admin/network/site-users.php b/src/wp-admin/network/site-users.php index 62c6212c3f..9501112c21 100644 --- a/src/wp-admin/network/site-users.php +++ b/src/wp-admin/network/site-users.php @@ -164,6 +164,13 @@ $title = sprintf( __('Edit Site: %s'), $site_url_no_http ); $parent_file = 'sites.php'; $submenu_file = 'sites.php'; +/** + * Filter whether to show the Add Existing User form on the Multisite Users screen. + * + * @since 3.1.0 + * + * @param bool $bool Whether to show the Add Existing User form. Default true. + */ if ( ! wp_is_large_network( 'users' ) && apply_filters( 'show_network_site_users_add_existing_form', true ) ) wp_enqueue_script( 'user-suggest' ); @@ -243,9 +250,16 @@ endif; ?> - + +/** This filter is documented in wp-admin/network/site-users.php */ +if ( current_user_can( 'promote_users' ) && apply_filters( 'show_network_site_users_add_existing_form', true ) ) : ?>

@@ -272,7 +286,15 @@ endif; ?>
- +