View Issue Details

IDProjectCategoryView StatusLast Update
0008206mantisbtintegrationpublic2007-10-04 01:40
Reportergiallu Assigned Togiallu  
Status closedResolutionfixed 
Fixed in Version1.1.0rc1 
Summary0008206: Add (gr)avatars for users

It would be nice to associate an avatar image to each user.

This coul be accomplished in various ways, but one of the simplest seems to be adding support for images

TagsNo tags attached.




2007-07-28 02:58

manager   ~0015250

I agree with the idea. At one point of time I was thinking of the same thing and the same website. I think I got the idea from one of the forums applications.

The question is where are we going to display the avatar? In some area we may have enough space to display it (e.g. next to issue notes) but in other we won't have the space.

Once place we can put it for sure is the User's Page which I had reserved a requirements wiki page for but never spec'd. This is similar to the project page I introduced lately.



2007-07-28 19:25

reporter   ~0015266

The avatar is fine where a username is shown so, IMHO, it's basically something for the bugnotes.

I think I will add a user_get_avatar function to return the avatar image URL: this allows multiple sources for the actual image storage.



2007-07-30 04:28

reporter   ~0015288

Do we want to add a configuration option for this?

If so, defaults to what?



2007-07-30 09:52

manager   ~0015297

Following are my suggestions:

  1. I think we should add a configuration option, $g_avatar_enable(d), and make it OFF by default.

  2. Consider adding avatar_api.php which includes: avatar_get() which takes $p_user_id and returns AvatarData (which includes URL, width, height). Width and Height can be -1.

  3. print_avatar( $p_user_id ), gets the avatar data and translated them to to an img tag.

  4. We can use a custom function to be called from with avatar_get(). This will allow users to override the default implementation. The other option is to use a driver model (like Wikis), where users can use configuration to choose a driver, drivers are in core/ like avatar_gravatar_api.php.



2007-08-05 09:44

reporter   ~0015352

  1. OK

  2. I'm not particularly attracted by creating a whole new API for a single function; moreover, an avatar is something tighly related to the user, so I'd prefer adding a user_get_avatar( $p_user_id ) function in the user api instead, returning the array(URL, width, height)

  3. ok

  4. I would leave this for later, so we can first see if and how the feature is used and eventually get feedback from users before deciding



2007-08-05 17:52

reporter   ~0015355

This is now in CVS. please note that:

  1. the config variable is named $g_show_avatar, more consistent to the other $gshow* configuration variables we have

  2. I added a default avatar to be used when the user do not have one. For now, since the implementation is based on gravatar, it is the one provided by them

Related Changesets

MantisBT: master df7758c3

2007-08-05 21:09:38


Details Diff
Fix 8206: Add (gr)avatars for users

git-svn-id: <a class="text" href="/?p=mantisbt.git;a=object;h=f5dc347c">f5dc347c</a>-c33d-0410-90a0-b07cc1902cb9
Affected Issues
mod - core/print_api.php Diff File
mod - config_defaults_inc.php Diff File
mod - css/default.css Diff File
mod - bugnote_view_inc.php Diff File
add - images/gravatar_logo.gif Diff File
mod - core/user_api.php Diff File