Docs: Add documentation for WP_Comments_List_Table::floated_admin_avatar()
.
Props akbarhusen, ayeshrajans, Soean, ajayghaghretiya1, netweb, SergeyBiryukov. Fixes #41491. git-svn-id: https://develop.svn.wordpress.org/trunk@47507 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
251fd685dd
commit
0f9477d5e8
@ -55,6 +55,15 @@ class WP_Comments_List_Table extends WP_List_Table {
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds avatars to comment author names.
|
||||
*
|
||||
* @since 3.1.0
|
||||
*
|
||||
* @param string $name Comment author name.
|
||||
* @param int $comment_ID Comment ID.
|
||||
* @return string Avatar with the user name.
|
||||
*/
|
||||
public function floated_admin_avatar( $name, $comment_ID ) {
|
||||
$comment = get_comment( $comment_ID );
|
||||
$avatar = get_avatar( $comment, 32, 'mystery' );
|
||||
|
@ -181,12 +181,12 @@ function get_pending_comments_num( $post_id ) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Add avatars to relevant places in admin, or try to.
|
||||
* Adds avatars to relevant places in admin.
|
||||
*
|
||||
* @since 2.5.0
|
||||
*
|
||||
* @param string $name User name.
|
||||
* @return string Avatar with Admin name.
|
||||
* @return string Avatar with the user name.
|
||||
*/
|
||||
function floated_admin_avatar( $name ) {
|
||||
$avatar = get_avatar( get_comment(), 32, 'mystery' );
|
||||
|
Loading…
Reference in New Issue
Block a user