Avatars or Gravatars for WordPress

Gravatar / Avatar
Gravatar / Avatar

Add More Default Avatar Choices to the WordPress Admin. Add the following code in the functions.php :

// Add More Default Avatars to Options
if (!function_exists('ss_addgravatar')) {
function ss_addgravatar($avatar_defaults) {
$myavatar1 = get_bloginfo('template_directory').'/images/avator/01.png';
$avatar_defaults[$myavatar1] = 'rock';
$myavatar2 = get_bloginfo('template_directory').'/images/avator/02.png';
$avatar_defaults[$myavatar2] = 'Cool';
$myavatar3 = get_bloginfo('template_directory').'/images/avator/03.png';
$avatar_defaults[$myavatar3] = 'Geek';
$myavatar4 = get_bloginfo('template_directory').'/images/avator/04.png';
$avatar_defaults[$myavatar4] = 'Pretty';
return $avatar_defaults;
$myavatar5 = get_bloginfo('template_directory').'/images/avator/05.png';
$avatar_defaults[$myavatar5] = 'Sexy';
return $avatar_defaults;
add_filter('avatar_defaults', 'ss_addgravatar');

If you want to get your globally recognized avatars then you can use Gravatars. An avatar or gravatar is an icon, or representation, of a user in a shared virtual reality, such as a forum, chat, website, or any other form of online community in which the user(s) wish to have something to distinguish themselves from other users. Created by Tom Werner, gravatars make it possible for a person to have one avatar across the entire web. Avatars are usually an 80px by 80px image that the user will create themselves.

Click here to get your own Gravatars.

One Reply to “Avatars or Gravatars for WordPress”