wrinkles
[ikiwiki] / doc / todo / avatar.mdwn
1 [[!tag wishlist]]
2
3 It would be nice if ikiwiki, particularly [[plugins/comments]]
4 supported user avatar icons.
5
6 Idea is to add a directive that displays a small avatar image for a user.
7 Pass it the email address, openid, or wiki username of the user.
8
9         \[[!avatar user@example.com]]
10         \[[!avatar http://joey.kitenet.net/]]
11         \[[!avatar user]]
12
13 These directives can then be hand-inserted onto pages, or more likely,
14 included in eg, a comment post via a template. Possibly included in a
15 recentchanges page item via that template too?
16
17 The avatars are provided by various sites. For email addresses, it uses a
18 [gravatar](http://gravatar.com/). For a wiki username, the
19 user's email address is looked up and the gravatar for that user is
20 displayed. (Of course, the user has to have filled in their email address
21 on their Preferences page for that to work.)
22
23 For openid, openavatar sucked and is now dead. So we need to use an email
24 address instead, I guess. Problem is that the email address of a given
25 openid is only known when that user is logged in and making a change.
26 And we don't want to leak an openid user's email into a page either.
27 Hmm. Suppose the gravatar hash could be calculated from the email address
28 and embedded instead of the openid?
29
30 Or, for openid, could use <http://paulisageek.com/openidavatar>.
31
32 An optional second parameter can be included, containing additional
33 options to pass in the 
34 [gravatar url](http://en.gravatar.com/site/implement/url).
35 For example, this asks for a smaller gravatar, and if a user does
36 not have a gravatar, uses a cute auto-generated "wavatar" avatar.
37
38         \[[!gravatar user@example.com "size=40&default=wavatar"]]
39
40 The `gravitar_options` setting in the setup file can be used to
41 specify additional options to pass. So for example if you want
42 to use wavatars everywhere, set it to "default=wavatar".