DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:avatar

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
plugin:avatar [2016-05-22 06:20] – [A bit more control] 85.9.60.46plugin:avatar [2018-04-27 17:43] – Compatible to "Greebo" LarsDW223
Line 6: Line 6:
 email      : freaks@dokuwiki.org email      : freaks@dokuwiki.org
 type       : syntax, helper type       : syntax, helper
-lastupdate : 2016-01-16 +lastupdate : 2017-08-25 
-compatible : Weatherwax, "Adora Belle", Angua, Rincewind+compatible : Weatherwax, "Adora Belle", Angua, Rincewind, "Greebo"
 depends    :  depends    : 
 conflicts  conflicts 
Line 25: Line 25:
   {{gravatar>[user|mail]?[size]|[title]}}   {{gravatar>[user|mail]?[size]|[title]}}
  
-^ [user]  | the registered user for which you want to display an avatar | required | +^ [user]   | the registered user for which you want to display an avatar                                                    | required                                            
-^ [mail]  | the e-mail address for which you want to display an avatar image | required FIXME| +^ [mail]   | the e-mail address for which you want to display an avatar image                                               | required FIXME                                      
-^ [size]  | either s(mall) = 20×20 pixel, m(edium) = 40×40 pixel, l(arge) = 80×80 pixel, xl (extra large) = 120×120 pixel | optional; default is medium | +^ [size]   | either s(mall) = 20×20 pixel, m(edium) = 40×40 pixel, l(arge) = 80×80 pixel, xl (extra large) = 120×120 pixel  | optional; default is medium                         
-^ [title]  | the name of the person the mail address belongs to or some other title text | optional; default is the obfuscated e-mail address |+^ [title]  | the name of the person the mail address belongs to or some other title text                                    | optional; default is the obfuscated e-mail address  |
  
 By padding the e-mail address with spaces you can define the alignment like with [[:wiki:syntax#images_and_other_files|images]]. By padding the e-mail address with spaces you can define the alignment like with [[:wiki:syntax#images_and_other_files|images]].
Line 59: Line 59:
 Instead of avatars coming from a fixed namespace, I would like to be able to specify a tokenized filename for the avatar.  For example, I have my DW set up so that each user has a "user namespace" in which they have full permissions, and I would like that avatar to come from that namespace.   Instead of avatars coming from a fixed namespace, I would like to be able to specify a tokenized filename for the avatar.  For example, I have my DW set up so that each user has a "user namespace" in which they have full permissions, and I would like that avatar to come from that namespace.  
  
-This is a lot easier to manage since there is no a-priori avatar, and thus ACL permission cannot be granted to upload the file - I want users to be able to change their own avatars without other users being able to; since you can't grant ''delete'' permission to a namespace, there is no way to stop users jhoverwriting each others' avatars unless they are in separate protected namespaces.+This is a lot easier to manage since there is no a-priori avatar, and thus ACL permission cannot be granted to upload the file - I want users to be able to change their own avatars without other users being able to; since you can't grant ''delete'' permission to a namespace, there is no way to stop users overwriting each others' avatars unless they are in separate protected namespaces.
  
 This can be achieved by changing the ''namespace'' conf setting so that it looks something like ''user/@USER@/avatar'' (perhaps even renaming so that it is called ''filename'', since that is a more meaningful description of the setting under this proposal).  This is then resolved in ''_getAvatarURL'' into the right form, e.g. ''user/my_user_name/avatar'', and then the files ''user/my_user_name/avatar.jpg'' etc are searched for. This can be achieved by changing the ''namespace'' conf setting so that it looks something like ''user/@USER@/avatar'' (perhaps even renaming so that it is called ''filename'', since that is a more meaningful description of the setting under this proposal).  This is then resolved in ''_getAvatarURL'' into the right form, e.g. ''user/my_user_name/avatar'', and then the files ''user/my_user_name/avatar.jpg'' etc are searched for.
plugin/avatar.txt · Last modified: 2024-02-26 13:30 by nerun

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki