Have implemented Gravatar on my blog.

What is Gravatar?
A gravatar, or globally recognized avatar, is quite simply an 80×80 pixel avatar image that follows you from weblog to weblog appearing beside your name when you comment on gravatar enabled sites. Avatars help identify your posts on web forums, so why not on weblogs?

Integration of Gravatar on my blog was simple.

I first installed the Gravatar Signup Plugin. It generates code with a checkbox when you comment giving you the option of signing up for Gravatar right from my blog.
Tested it by signing up for Gravatar myself.

You receive a confirmation email from them and all you have to do is click on the link. Next I uploaded my image.
My Gravatar

Next step was implementing it on my blog.
Firstly, I installed the WordPress Gravatar Plugin.

Then I editted my themes CSS file and added this code:
.gravatar {
position: relative;
float: right;
margin: 0 0 2px 5px;
padding: 0;
clear: both;
}

Then I editted my themes comments.php file and added this in the comments loop:
<img src="<?php gravatar("", 60); ?/ >" alt="Gravatar" class="gravatar" />

This ensured that all the gravatars are of size 60px. As of now I am enabling all gravatars. However, if I do notice obscene ones, I will need to sensor it.

BTW, the comment loop is between:
<?php foreach ($comments as $comment) : ?>
and
<?php endforeach; /* end for each comment */ ?>

That’s it folks :)

Subscribe to the Feed
Liked this article? Stay in touch with us! Don't forget to Stumble It!
Grab the site feed or add to your Technorati favs.


Post Details

Post Date :
Saturday, Mar 12th, 2005 at 5:30 pm
Category :
Blogging and Computers & Technology
Tags :
,
Do More :
Both comments and pings are currently closed.

Related Posts

Some posts related to the post you have just read:

Search this site for Related Posts

Google