if ( isset( $_REQUEST['order'] ) )
$args['order'] = $_REQUEST['order'];
- $mode = empty( $_REQUEST['mode'] ) ? 'list' : $_REQUEST['mode'];
+ if ( ! empty( $_REQUEST['mode'] ) ) {
+ $mode = $_REQUEST['mode'] === 'excerpt' ? 'excerpt' : 'list';
+ set_user_setting( 'network_users_list_mode', $mode );
+ } else {
+ $mode = get_user_setting( 'network_users_list_mode', 'list' );
+ }
/** This filter is documented in wp-admin/includes/class-wp-users-list-table.php */
$args = apply_filters( 'users_list_table_query_args', $args );
'blogs' => __( 'Sites' )
);
/**
- * Filter the columns displayed in the Network Admin Users list table.
+ * Filters the columns displayed in the Network Admin Users list table.
*
* @since MU
*
}
/**
- * Handles the blogs/sites column output.
+ * Handles the sites column output.
*
* @since 4.3.0
* @access public
$path = ( $val->path === '/' ) ? '' : $val->path;
echo '<span class="site-' . $val->site_id . '" >';
- echo '<a href="'. esc_url( network_admin_url( 'site-info.php?id=' . $val->userblog_id ) ) .'">' . str_replace( '.' . get_current_site()->domain, '', $val->domain . $path ) . '</a>';
+ echo '<a href="'. esc_url( network_admin_url( 'site-info.php?id=' . $val->userblog_id ) ) .'">' . str_replace( '.' . get_network()->domain, '', $val->domain . $path ) . '</a>';
echo ' <small class="row-actions">';
$actions = array();
$actions['edit'] = '<a href="'. esc_url( network_admin_url( 'site-info.php?id=' . $val->userblog_id ) ) .'">' . __( 'Edit' ) . '</a>';
$actions['view'] = '<a class="' . $class . '" href="' . esc_url( get_home_url( $val->userblog_id ) ) . '">' . __( 'View' ) . '</a>';
/**
- * Filter the action links displayed next the sites a user belongs to
+ * Filters the action links displayed next the sites a user belongs to
* in the Network Admin Users list table.
*
* @since 3.1.0
}
/**
- * Filter the action links displayed under each user in the Network Admin Users list table.
+ * Filters the action links displayed under each user in the Network Admin Users list table.
*
* @since 3.2.0
*