Gravatar Signup Encouragement

Gravatar Signup Encouragement (download) is a plugin that will encourage users without avatar on Gravatar to make one. It checks e-mail address that unregistered users enter in forms or stored e-mail address of registered users on gravatar.com to see if there is avatar associated to that e-mail address. If there is no avatar, it will display message which will inform user that they don’t have an avatar on Gravatar and give them a link to sign-up page of Gravatar which would be pre-filled with their e-mail address.

Checks on gravatar.com for user’s e-mail address are done via simple and fast AJAX.

Message can be shown to:

  • unregistered commenters when they leave text input field for e-mail address
  • registered commenters to whom their registered e-mail address is checked
  • unregistered commenters after they post a comment in a dialog, to whom their entered e-mail address is checked
  • registered commenters after they post a comment in a dialog, to whom their registered e-mail address is checked
  • registered users in administration notices, to whom their registered e-mail address is checked
  • registered users in admin bar, to whom their registered e-mail address is checked
  • registered users on their profile page, to whom their registered e-mail address is checked
  • users who fill registration form when they leave text input field for e-mail address

There is no need for editing of theme’s files in order to show message, everything is done via JavaScript.

Both AJAX and display of messages are done with use of jQuery library. This plugin will load jQuery file to head of your page if it wasn’t already loaded by theme or other plugin(s). You can speed up your web site and save on bandwidth and server resources with use of plugin Use Google Libraries which will load jQuery file from Google AJAX Libraries. See here how will this help you.

You can select in what of eight (plus one on multisite or in bbPress) cases to show message, plus you can choose for each case where on page to show message. There are several elements already available to choose for all cases and you can alternatively add custom element by providing it’s id. Since this plugin uses jQuery selectors to find element, you can add even more advanced filters for selecting. Also be aware that display of message may not look good with your theme.

Customization of styles of messages is also possible. You can customize messages by defining CSS style of it. Whole message is wrapped with div with ID depending on case:

  • gse_comments_message for comment form
  • gseaftercommenting for modal
  • gse_admin_notice for administration notice
  • gse_profile_message for profile page
  • gse_registration_message for registration page
  • gse_ms_signup_message for signup page on multisite
  • gse_bbpress_message for bbPress

Text of a message is also customizable, you can write any message you want, even use HTML tags you want. Note that you should leave link with URL placeholder if you want to show link to Gravatar’s signup page pre-filled with user’s e-mail address, and that you should not use double quotes (") since it will break code. Instead, use curly quotes ( and ) for text, and single quotes (') for HTML tags. Also note that same message is shown for all cases, unless you use WordPress filters to change it per case.

There will be no mess in database made by this plugin, since it adds only one field in database which is deleted if you uninstall plugin using WordPress’ built-in feature for deletion of plugins.

This plugin is fully internationalized, you can translate all text and link to locale version of Gravatar’s site. You can find .pot file in translations folder where you should place your translation. Please send me your translation by contacting me so that I can include it in next releases.

Editing of settings is done on page Discussion Settings in administration area of WordPress, in section Avatars. Here is a screenshot of how settings should look with all cases checked.

Settings form with all expanded options

Here are screenshots of displays of message in all cases with default settings.

Message shown to unregistered commenter on default theme with default settings

Message shown to registered commenter on default theme with default settings

Message shown in a dialog to unregistered commenter on default theme with default settings after posted comment

Message shown in a dialog to registered commenter on default theme with default settings after posted comment

Message shown in admin bar

Message shown in administration notices

Message shown on a profile page with option to show below “Profile” header

Message shown on a registration page with default settings

Message shown on a registration page (multisite) with default theme and default settings

Message shown in a bbPress reply form of a Twenty Eleven theme in line with avatar

And here is video tutorial (don’t forget to turn on captions (subtitles) since this is where you’ll get text):

Gravatar Signup Encouragement is released under the terms of GNU General Public License. It is completely free so if you find it useful you can give something back to author. Your help could be done by giving donation, translating plugin to your language, sending bugs and suggestions, promoting plugin in blogs, forums social networks, and other websites.

Support for this plugin could be get in comment section of this page or (preferably) through WordPress support forum. Note that I don’t guarantee that I’ll respond to your entries nor that I’ll do it in short period of time. Before posting, please read documentation on this page or on plugin’s page in WordPress plugin directory. I’ll may delete questions for which answers are provided.

60 responses to “Gravatar Signup Encouragement”


  1. [...] 18th, 2009 Gravatar Signup Encouragement is my first publicly released plugin for WordPress. I got idea to write it after reading comments [...]

  2. BG!


    What a great plugin!

    One minor problem, though… when I installed and tested it, it did correctly show the message when I entered an email address with no Gravatar. However, when I changed the email address to one which does have a Gravatar, the message did not disappear. This could mislead some folk.


  3. Gravatar Signup Encouragement: затягиваем пользователей в сети Gravatar…

    Еще один плагин (летом я писал о Gravatar Box), призванный популяризовать использование сервиса «глобальных аватаров» – Gravatar. Сервис Gravatar запущен давно и достаточно популярен. Многие блоггеры использует поддержку «гло……

  4. BG!


    I have upgraded to Version 0.94.8 and it works fine.
    Thank you for fixing this.


  5. [...] Зато сам ја направио додатак за Вордпрес под називом „Подстицај учлањивања на Граватар“ који за циљ има да корисницима који немају граватар [...]


  6. [...] 11th, 2009 With my new plugin, Gravatar Signup Encouragement, I had a problem with translation of string that is used only on [...]

  7. Stéphane Gallay


    Great plugin! But now that I switched to the Carrington theme, it seems not to be working anymore. Is there something to add to a template?

  8. Stéphane Gallay


    Sorry, only noticed now that you had replied.

    I’ve checked and cannot see any active, comment-related plugins. I had changed a few items in the theme but I don’t recall fiddling with the comment form, although I still have to get familiar with Carrington’s weirdish structure.

    I’m using the latest version (Carrington Blog 2.2), by the way.

  9. Stéphane Gallay


    Thanks for this, I’ll try that this week-end.

    Now I’ve seen the email notification widget. :)

  10. Ollie Snyder


    The more I try these things the more depressed I get for being such an obvious dunce. I have tried to do everything step-by-step and I don’t see the suggestion anywhere on my site. Can someone take a look and give me a clue where I made the mistake? I’m at the point where I’d share the ID &PW with you to find the problem.


  11. [...] Gravatar Signup Encouragement is a simple plugin that encourages users without an avatar on Gravatar to make one!  It creates a prompt (and link to the website) for any user who’s email was not found on file at Gravatar. [...]


  12. [...] Gravatar Signup Encouragement. Encourages commenters who do not already have a Gravatar to sign up for a free Gravatar. [...]

  13. John


    First of all, thanks for creating a awesome plugin. However, I’m having one problem with it and I think that it might be related to the Mystique theme that I’m using.

    The problem is this: When a first time visitor that doesn’t have a gravatar account visits my website and wants to leave a comment, they are not presented with the encouragement to sign up for an Gravatar account. The comment is suppose to pop up under the Comment box and above the submit button but it doesn’t. My guess is that the comments.php is causing the problem as the encouragement message shows when you create a new account or when a login in user doesn’t have a gravatar.

    A screenshot of the setting page can be viewed at this link: http://screencast.com/t/NzQ2MTQx

    I would appreciate any help that you can provide.

  14. Wong Choon Jie


    I think I found a bug. At the comment area, if an e-mail (without Gravatar) is input, the message pops up. That’s good. And if you replace the email address (without Gravatar) to another email address (with Gravatar), the message automatically disappears. That’s even better! The problem is that this message does not disappears on its own at the register page. Once the message pops up, it remains there (until you navigate away, of course). Could you please solve this problem? I am not sure if this problem is present on the profile page, though.

    It’s a great plug-in. It does exactly what I want as if you can read my mind! Keep up the good job!!

  15. clubside


    Howdy! Really like the simplicity of this plug-in, but I have two problems: first it says I don’t have a Gravatar (which I do), and second when the browser auto-populates forms the routine never runs (you have to manually go to the email box and type something to refresh it). I have no idea why there is a problem looking up the existence of my Gravatar, but the second issue could be solved by a jQuery after load event that checks to see if the box is already filled out, right?

  16. Jake


    I am trying to use this plug in on a website located at http://fbcflomaton.com/wordpress/?page_id=3 I cannot get it to show on the comments nor can I get it to show on the dashboard for users who are not registered with gravatar. Any help would be greatly appreciated. Thanks.

  17. Lance


    This plugin is just what I’ve been looking for, but I haven’t been able to make it work on my site. Here are my settings:

    http://dl.dropbox.com/u/3619118/gravatar.png

    As you can see, I’m trying to use the message everywhere — registration, comments, and profile. Unfortunately, I don’t see it appearing in any of those places.

    I have not required registration for comments. I’m using a custom StudioPress theme and do not have any other comment-related plugins. Any idea what I might be doing wrong, or how to fix the problem if it’s an incompatibility with the theme?

    Thanks for your time!

  18. Lance


    Thanks for the reply, Milan.

    I assume you’re referring to the double quotes (“) in the Gravatar URL. I replaced them with single quotes (‘), and the problem persists. The message still does not appear on the registration, comments, or profile pages.

    Any other ideas?


  19. [...] Gravatar Signup Encouragement encourages users without a Gravatar to make one. [...]

  20. Nina


    Great plugin! For some reason, though, it shows the message even when I type an e-mail that already has a gravatar… I feel kinda dumb but I can’t figure out why it’s doing this. :(

  21. Christoph


    Hi, thanks for the useful plugin! Works all as it should, but when I reply to a comment while I’m logged in as admin (with a non-standard username, if this makes a difference) it just takes me to an empty page /wp-comments-post.php – and that’s all. The comment is properly submitted, but I think it should redirect me back to the post. If I disable your plugin the redirection works. Any idea?

  22. Steve Carter


    I’m having a problem with the message: “Notice: The latest version of the Gravatar Signup Encouragement plugin has new options….”

    I click on: Yes (edit Gravatar Signup Encouragement settings); make the changes and save them the warning/notice message disappears. However when I go back to the Dashboard the message re-appears. The plugin seems to be working fine otherwise. Am I doing something wrong or is there a flaw in the plugin?

    Thanks in advance for your time and attention!

  23. Steve Carter


    Milan — Thanks for your quick reply. I hate to be such a dork but I’m not finding where I need to go to find Options > Discussion. I’ve tried looking in all the obvious and not so obvious spots and can’t seem to find it.

  24. Shane


    I’m having the same problem as Nina, where all emails give the gravatar encouragement modal, whether they have a gravatar registered already or not.

    I have get_headers enabled and I’ve tried changing the 200 to 404 line.

  25. James Dibben


    I’ve got one slight issue. I’ve chosen to have the message appear below the URL. For some reason it’s pushing the label “URL” down to where it’s at the end of the message right above the comment box.

    Can this be fixed easily?

    http://bluecollarcoaching.net/why-i-follow-brent-green#more-748

  26. Michael Harris


    Thanks for checking — I think I deactivated the plug-in before you got there though, because it showed up at every place for a comment. I have re-activated it until I hear back from you so you can see it. I set up a temporary fake account for you to try it out.
    Thanks!


  27. [...]   新添加的插件,External Links,文章内容中的外部链接的标示就是用它实现的。Gravatar Signup Encouragement,如果评论者填写的邮件没有用Gravatar,会给一个提示,引导他去设置头像。这两个插件都可以用代码实现,懒得折腾了,腻了就停掉。 [...]

Leave a Reply

Comment Guidelines:
  • Fields marked with * are required
  • If you want your picture next to comment, open an account at Gravatar
  • If you want to know if someone replied to your comment, check “Notify me of followup comments via e-mail”
  • You can use these XHTML tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>