Gravatar Box

Plugin: Gravatar Box
Version: 1.0.4
Last updated: 8 years ago.
Downloaded: 16,242 times.

Overview

Gravatars are great. But many people don’t have them.

Wouldn’t it be nice if, when a user was filling in the comments form, the page could automatically detect and show a users gravatar, if they have one? Or even better, show a sign up link if they don’t have one?

Well, here you go.

Download Now

Requirements

WordPress 2.8 or higher.

Features

  • Easy to install and use.
  • Integrates easily into any theme, with only one line of code.
  • Easily customizable through CSS styling.
  • No complex interface or options to mess with, just works.

Installation Instructions

  1. Upload the files to the `/wp-content/plugins/gravbox/` directory
  2. Activate the plugin through the ‘Plugins’ menu in WordPress
  3. Add this to your comments form somewhere:
    <?php if (function_exists('gravbox')) gravbox(); ?>
  4. Add styling for it into your style.css.
    The gravbox() code adds a div with id of “gravbox”.
    The image has the “gravatar” class, and is wrapped inside another div with a class of “gravatar_frame”.
    The no-gravatar link is inside a p with a class of “nogravatar”.
    This should be enough for any styling needs. If you wish to further alter the result or the size of the gravatar, edit the gravbox.js file.

Licensing

This plugin is licensed under the GPL Version 2 only.

Method to get support

You are free to email me, however I am also a moderator at the WordPress.org support forums, so you’ll find me there as well.

Download Now

27 Comments

  1. Howdy! I really love the concept of this plug-in as one of the sites I manage has a lot of people who don’t know what a Gravatar is, but it doesn’t seem to do anything in the user isn’t logged in to WordPress, it just renders an empty div with the indicated ID. Any ideas?

  2. […] Deze plugin voorziet in een simpele voorbeeld weergave van de profielfoto zodra iemand zijn mailadres invoert. Heeft iemand nog geen GRAvatar, dan geeft de plugin dat ook aan en voorziet een link waar de commentator een GRAvatar kan aanvragen. […]

  3. Good news, your plugin is working in WP3.0 beta 1!

  4. Trying to test the pluggin again… page bombed

  5. How about some screenshots about how it works?

  6. i just downloaded this plugin and followed the instructions and it’s not working, so i’m here trying your leave a comment box to see if it works on your site

  7. and on your website it give me an avatar that i did not set up

    • I haven’t enabled the Gravatar Box plugin on this site yet. Been a while since I used it.

      And the reason it gave you that avatar is because you don’t have an actual Gravatar on gravatar.com.

  8. For those using the comment_form function, you might want to update your above instructions (since, when using comment_form(), using Gravatar Box is no longer as easy as adding one line of code). Here’s what I did (you may/probably have something even better):

    Add the following to functions.php

    /* Add Otto's Gravatar Box to the comment form, using the comment_form_before_fields hook. */
    function cbnet_gravatar_box() {
    if (function_exists('gravbox')) gravbox();
    }
    add_action( 'comment_form_before_fields', 'cbnet_gravatar_box' );

  9. Hi
    I have a question, my gravatar box is working just fine except that when i go from a post to another, the gravatar stays thr “no gravatar” one, even if an email is pre-entered (because of the cookies the viewer has).
    If i click on the email then on an other textbox, the gravatar show up. Is there a way to make this work or is something in my theme ?

  10. Wow it took me some time to find this page, maybe you should change the plugin homepage link on
    http://wordpress.org/extend/plugins/gravatar-box/changelog/

    My question on
    1.0.4
    * Modified to use new 3.0 comments form hooks. No need to edit the theme’s comments form anymore, if your theme supports it!

    1) So if it worked before I should not need to update?
    2) How can I change my old theme that it uses the modern 3.0 comments form hooks?

  11. Wow – this is nice. I certainly advocate of blogs with Gravatars it just works better when you get a face on. Thanks for sharing.

  12. That’s cool. Specially for the people who have no clue as to how to display the profile pic..

  13. Could someone kindly tell me what i need to do to this code to make it launch the link in a new _blank window? I tried “target=_blank” but it doesn’t seem to happen for me!

    .error(function() {
    $('#gravbox').html("This prompt appears because you DO NOT have a Gravatar for your email address. A Gravatar puts an image next to any comment or post you make on an blog you visit world wide. It's recommended you get one!");
    })
    .attr('src',gravatar(email)+"?s="+size+"&d=404");
    });
    });

  14. Otto box isn’t worth it. I dropped once & plastic case top came off & got crack screen ( Otto box screen ). It’s not worth 50.00 even 20.00 too.

  15. which the theme is very compatible to this plugin ?

  16. […] and shows in real-time the Gravatar image when users are filling the comment form.Fork of the Gravatar Box plugin by Otto, based on the MooTools javascript framework (instead of jQuery), with a nice fading […]

  17. good plugin, using this on my blog 😀 thanks

  18. Where do I add this function in Thesis wordpress theme?

  19. […] Gravatar Box zorg je ervoor dat er gravatars naast de reacties komen van de mensen die gereageerd hebben. […]

  20. Is this plugin still being supported?

Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

Need to post PHP code? Wrap it in [php] and [/php] tags.