Author Avatars List

Description

This plugin makes it easy to display lists of user avatars, grouped by user roles, on your (multiuser) site. It also allows you to insert single avatars for blog users or any email address into a post or page – great for displaying an image of someone you’re talking about.

It makes use of built in WordPress (core) functions to retrieve user information and get avatars.

Avatar lists can be inserted into your sidebar by adding a widget or into posts/pages by using a shortcode. The plugin comes with a tinymce editor plugin which makes inserting shortcodes very easy.

Please help with the plugin Translations at https://translate.wordpress.org/projects/wp-plugins/author-avatars.

Both the shortcode and widget can be configured to:

Show a custom title (widget only)

Only show specific user groups and/or hide certain users

Limit the number of users shown

Change the sort order of users or show in random order

Adjust the size of user avatars

Optionally show a user’s name or biography

Show users from the current blog, all blogs or a selection of blogs (on WPMU/Multisite)

Group users by their blog (when showing from multiple blogs), and show the blog name above each grouping.

FAQ

Shortcode, huh?

A shortcode is a tag like [authoravatars] which you can insert into a page or post to display a list of users on that post/page. You can read more about shortcodes in general in the wordpress codex, for example here or here.

How do I use the author avatar shortcode?

As of version 0.6 the plugin comes with a tinymce plugin which makes it very easy to insert shortcode(s).

If you’d like to do it manually it’s still simple: just add [authoravatars] into your post and hit save! There’s a large number of parameters available.

The plugin comes with two shortcodes: [authoravatars] for lists of avatars and [show_avatar] for single avatars.

I can’t get my widget to show users from multiple blogs!

Make sure you have enabled the « blog filter » in Site Admin / Author Avatars for the blog on which you are trying to use this feature on. By default this is only enabled for the root blog (blog id = 1).

The plugin uses the WordPress Core Template function get_avatar() to retrieve the actual avatar images. In order to display custom images you need to look for plugins which use/override WordPress’ avatar features and provide respective upload features…

I get a « 404 Page not found » error when I click on the avatar of a user!

This can happens when you’ve choosen to link users to their « author page » and the user has not written any posts on a blog. There are two things that you should do in this situation:

To prevent the 404 page from showing up install the Show authors without posts Plugin. This forces WordPress to always show the user page if the user exists.

If not already there add a custom user/author template to your theme. Otherwise if a user has no posts their user page is going to be quite empty by default…
You can find a tutorial on Author Templates as well as a Sample Template File in the WordPress Codex.

Can I use html in user biographies?

WordPress Core unfortunately strips all html from the user biography field when entered. Install the plugin Weasel’s HTML Bios if you want to use html…

How can I change the styling of the avatar lists?

The styling of the widget is controlled by the styles defined in css/widgets.css, avatars on posts/pages (using the shortcode) are styled by code in css/shortcode.css.

You can override the styles in that file by copying a style block to your theme’s style.css and adjusting respectively. For example add the following to remove the padding from avatars displayed in a widget:

Hi!
I love this plugin because its the only one that gives me the option I need. There is one thing I don't like. The aligning. I put the widgit on the bottom of my site but the aligning is gradually. I want to align the avatars horizontally next to each other with the names under the avatar. Have a look on my website [Link redacted] Any suggestions? Thanks for the reply and greeting from the Netherlands!

1.13

1.12

1.11

1.10

1.9.9

fixed typo
fixed filter name
fixed advance option not showing in widget form

1.9.8

Added Filter aa_user_raw_list

1.9.7

Added filter aa_user_show_last_post_query
Added the ability to use any URL in the profile contact section as a link
Added the ability for user_link to accept a comma-separated list as fall through if a URL is not found in first selection
Added contact_links to the short-code

1.9.6

readme update
removed php 4 constructors

1.9.5

Added sorting by white list values

1.9.4

Added white list for users

1.9.3

renamed function causing redeclare error

1.9.2

Added aa_user_show_last_post_type filter to allow setting of post type for last post link
added defaulted to author page if no last post is returned

1.9

fixed problem with WP 4.4 and widgets not saving
Add help translate link

1.8.8

set the page count to start at 1 not 0
Added support for UM profiles links

1.8.6.6

1.8.6.5

Added filter (aa_user_level_for_editor) to allow control of who can see the tinyMCE editor button
Added last_post_filter option to link options
Fix the truncating of bio in single avatars
Changed AA in filter names to aa

1.7.1

bubfix removed an extra ‘ in a SQL select in get_user_last_activity() function. Thanks to « basaja » for the bug report.

1.7.0

Added Local User select to Single Avatar Shortcode creator

Replaced wp_specialchars() with esc_html()

Added BBPRESS_post_count as shortcode dispaly and sort options

Added show_email to shortcode display option

Added some translation updates

Fixed issue with TniyMCE breaking when using HTTPS

And a few other tidy ups

Added SQL fliter to only fetch the users for the rolls being requested rather than all users

Added caching to the main get_users function which will use an object cache if turned on

1.6.3

Wraped ordering code in « remove_accents » functions to to replace Uni-code accents with non unicode versions so sort works as expected.

Increased height of TinyMCE popup so content shows with scroll bars.

Replaced text donate links with image link.

1.6.2

Added display options for single Avatar options

Added donation link

1.6.1

Fixed a bug that stoped the loading of default CSS sheet for the plugin that I added a bug in in 1.6

1.6.0

Added the option to link to BBpress profile in the link to the shortcode and generator user_link=bbpress_memberpage

Fixed bug – the the shortcode generator was shown up in the tinyMCE edit if it was loaded on a page (BBpress forum posts) the popup was 404’ing so add a $pagenow != ‘index.php’ to make sure we are in the addmin section