dominoGuru.com

Your Development & Design Resource

Site News: Facebook, Gravatars, MDn Hashes, and why stealing is fun!

Tastes like 
Chicken! I've been tweaking this site lately, adding -- what I hope -- are improvements. Some of these tweaks have come in the type of content featured on this site... but I'll talk about content changes later. Now, let's talk about a few of the visual enhancements I've added to the site recently:

To start, I'll mention that I've added a Facebook Fan Box (which sits to the right, directly above the Google Friend Connect gadget) for this site's Facebook Fan Page -- which currently has 651 Fans!

The next I'd like your opinion on. I've been told in the past that I should trust the whitespace, but I thought that the individual entries on the main page of dominoGuru sort of bled into each other. To break this up, I've added a document icon/image to the left of each entry title. Thoughts?

One of the other recent modifications of the site was the addition of Gravatar to the Comments section of the site. The idea behind Gravatar is simple: A user can create an account on Gravatar and add an email address (or multiple email addresses) to their account, as well as an avatar. All I need to do is perform an MD5 Hash on that email address -- which you give me when you comment -- and use that as your avatar image. Simple right? Here's the Formula:

"<img class=\"gravatar\" src=\"http://www.gravatar.com/avatar/" + mailaddress_hash + ".jpg?s=48&d=http://www.dominoguru.com/gravatar.png\" alt=\"" + @Name([CN];author) + "\" title=\"" + @Name([CN];author) + "\" />"

I first thought that I'd be able to do an @Password hash on the mailaddress NotesItem to eval the mailaddress_hash value on-the-fly... until I found out that @Password uses an MD2 Hash... and Gravatar was designed to use the aforementioned MD5. This meant that I could do one of two things:

While the JavaScript library approach was easy enough to implement, it would not have addressed the existing 1,500+ comments on this site... so I created a new instance of the IBM Domino Blog and ripped what I needed.

Three things I came away with here:

First, it was easy. Really easy.

Second, cannibalization is fun! I wasn't kidding when I said standing on the shoulders of giants -- there's a ton of great code out there that addresses a lot of issues. Hell, most of the downloads on OpenNTF.org should be treated as required reading for any Lotus Notes and Domino application developer!

And Third... not many people use Gravatar. For those of you that do (and submit your Gravatar'ed email address with your comment), you'll see your avatar in all its 48x48 glory!


About the author: Chris Toohey

Thought Leadership, Web & Mobile Application Development, Solutions Integration, Technical Writing & Mentoring

A published developer and webmaster of dominoGuru.com, Chris Toohey specializes in platform application development, solutions integration, and evangelism of platform capabilities and best practices.



More from dominoGuru.com


dominoGuru.com is powered by IBM Notes Domino XPages & hosted by Prominic.NET

Contact Us

Use our Contact / Feedback form or one of these email addresses:

Creative Commons License

Except where otherwise noted, dominoGuru.com by Chris Toohey is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.