Index: openacs-4/packages/xowiki/tcl/includelet-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/includelet-procs.tcl,v diff -u -r1.87 -r1.88 --- openacs-4/packages/xowiki/tcl/includelet-procs.tcl 23 Dec 2008 14:49:49 -0000 1.87 +++ openacs-4/packages/xowiki/tcl/includelet-procs.tcl 26 Dec 2008 02:29:16 -0000 1.88 @@ -3383,4 +3383,30 @@ #if {$title eq ""} {set title $url} return $content } +} + + +namespace eval ::xowiki::includelet { + ############################################################################# + # gravatar + # + # user image based on email address + # for details: see http://en.gravatar.com/ + # + ::xowiki::IncludeletClass create gravatar \ + -superclass ::xowiki::Includelet \ + -parameter { + {__decoration none} + {parameter_declaration { + {-email:required} + {-size 80} + }} + } + + gravatar instproc render {} { + my get_parameters + package require md5 + set md5 [string tolower [md5::Hex [md5::md5 -- $email]]] + return "$email" + } } \ No newline at end of file