WP_MS_Users_List_Table::column_username( WP_User $user )

Handles the username column output.


Description Description


Parameters Parameters

$user

(WP_User) (Required) The current WP_User object.


Top ↑

Source Source

File: wp-admin/includes/class-wp-ms-users-list-table.php

	public function column_username( $user ) {
		$super_admins = get_super_admins();
		$avatar	= get_avatar( $user->user_email, 32 );
		$edit_link = esc_url( add_query_arg( 'wp_http_referer', urlencode( wp_unslash( $_SERVER['REQUEST_URI'] ) ), get_edit_user_link( $user->ID ) ) );

		echo $avatar;

		?><strong><a href="<?php echo $edit_link; ?>" class="edit"><?php echo $user->user_login; ?></a><?php
		if ( in_array( $user->user_login, $super_admins ) ) {
			echo ' &mdash; ' . __( 'Super Admin' );
		}
		?></strong>
	<?php
	}

Top ↑

Changelog Changelog

Changelog
Version Description
4.3.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.