Please put some pictures in the block
| Project: | Affinity |
| Version: | 5.x-1.0 |
| Component: | Miscellaneous |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Hi,
I've been running this module on my live for few weeks now. Awesome module! I talk to my users regularly to see what they like and what they would like to see, so my request is based on that.
1) Please put user avatars 30x30 before the usernames
2) Please put a matching percentage thermometer after each username (Digg.com usually displays such a scale with % percntage match indicator). Varying percentage match indicators visually express better what this block is about, rather than it's title.
and (this one is from me personally)
3) Please allow administrators to exclude various users from ever being displayed (useful if you don't want user1 or other accounts being constantly pestered with buddylist requests)
What do you think?

#1
Good stuff!
I'll make 1 & 2 options in the settings form.
For 3, I'll make it user roll based. I.E. the admin will enable the user rolls eligible to be considered in the matching algorithm.
Thanks,
sicjoy
#2
Thanks Sicjoy!!!
Avatars always create a "community feel" and visualizations like a percentage thermomenter always add to usability. So this will be a great addition.
I think User1 should also be automatically excluded (because, A) user1 doesn't fall under any roles and B) it is in Drupal's best practices in terms of security to always keep user1 separate). Or maybe some kind of additional checkbox "Exclude user1" could take care of that.
If you need testing it on a live and actively used site, please let me know.
#3
Hi Drupalina:
The 5.x-1.x-dev version now has a user pictures option in the affinity block settings: admin/build/block/configure/affinity/0. You'll need to set up a default picture for any users who don't opt to upload a picture. This can be done at admin/user/settings. Otherwise, the block will look ugly and disorganized.
Please test and let me know of any issues.
I am still working on the other features.
As far as the %match thermometer goes, I'm not a graphic artist. Do you know of any free icon sets that could be used?
Cheers,
sicjoy
#4
Hi Sicjoy,
I've just tested the .dev version on my live site. It works like a charm! LOVELY!!! Now users can actually see pictures of their potential "friends".
I just ticked the box that says "Use user pictures" in Affinity block settings. That's it, right? no other settings?
And the additional good news is that your .dev module also works seemelessly with the ImageCache Profile module, which I have up and running on my site.
My only comment at this stage is to allow the admins to exclude various users (like user 1, 2, 3,7,12), especially user 1, from being listed in the block. But I think, I've mentioned this before.
I'll get back to you regarding the thermometer backgroung image for the percentage maches to be displayed under the user names in the block.
#5
Fantastic! Yes, that's it. One other thing to note: make sure you set up a default user picture for your site. Otherwise, the affinity block looks strange for matches who haven't uploaded a picture.
I checked the code, and user 1 is already excluded from affinity matches. More specifically, user 1 can receive matches, but will not be matched to other users, i.e. will not show up in other users affinity block.
I'm working on the ability to exclude other users by role. That should be done shortly.
#6
No, my user 1 is still being displayed in the Affinity Matches block :( [I'm using the Jan 06 2009 .dev version]. So there's something wrong there.
I don't know if you're seen how Digg is displaying the affinity, but here I'm attaching 2 screenshots: 1 of Digg's version of affinity block and one of my own (I'm not a grafix artist, so sorry about the sketchy picture).
I'm not sure if what they use as a background to percentage indicators is an a single image, because percentages vary, and so to the thermometer indicators.
But it's definitely worth getting the percentage and thermometer indicators to work, because it is very visual and immediately encourages users to establish community relations with people they don't know.
#7
the above atachment is how Digg.com is doing it.
I forgot to attach my own version. Se the attachment below.
#8
Update: I've just ungraded to the latest Dev version (Jan 24, 2009 version), and user1 is still being displayed as affinity match to ordinary users. There is no new option in the block configuration or Affinity settings.
Percentages: I think for now if the block just displays the percentages even without the "thermometer" background, that would alread be a nice touch.
#9
Ah, I see a mistake in the code that allows user 1 to be included. A fix is forthcoming.
#10
There's one important thing to note when testing this fix: The match block is cached until a new vote is cast. In other words, if user 1 was in someone's affinity block before the fix, he will remain there until a new vote is cast.
--sicjoy
#11
OK - It looks like the thermometer is working in today's dev release. Please test and let me know if you find any problems.
Cheers,
sicjoy
#12
Hi,
I've tried the most recent 5x .dev version on my live site. Excellent features!!! The thermometer is great, and I think you included the buddylist exclusion feature as well.
I want to point out just 2 minor problems with this latest .dev release:
1) It looks great in Firefox, but in IE6 I can't get the CSS to display it properly. I'm attaching a screenshot of what it looks like on my live site in IE6.
2) For some of the older users ... like the original users, the thermometer readings are off the chart: 300%, 200% etc... It should never go above 100%. I attach a screenshot of what it looks like ... the screen scretched on and on.
#13
OK - I'm working on the browser compatibility issue. Blasted IE6! I should have something working this weekend.
As far as the off the chart thermometer is concerned, I believe this is the result of the old ranking scheme being left in the affinity match cache. I had to change the scheme from a pure vote count to percentage of votes cast for the thermometer.
I should provide a reset button to clear the old cache values in the admin settings. You could uninstall the module then reinstall it to clear the cache. I know that's a pain but it should fix this issue going forward until I can write the code for the reset button.
Cheers,
sicjoy
#14
One other, less painful, thing you can do to clear the cache. If you feel comfortable using drush, phpMyAdmin, or the mysql command prompt, execute the following query on your drupal database:
TRUNCATE affinity_matches;That should solve your off the chart thermometer problem.
--sicjoy
#15
re off-the-chart: Yes, that problem seems to go away after that user casts a few votes. I also disabled and then re-enabled the module, so that should sort the database cache truncation.
I should say, though: this is becoming one uber-cool module ;)
#16
ARRRG! Hopefully, I've overcome the browser compatibility issues with the thermometer CSS! What a pain! Thanks IE! ;-)
Also, I am now truncating the affinity database when you run update.php, so that should take care of the legacy cache data.
Yes, your buddylist social network is being excluded from matches, but this needs more work. Mainly, adding a new buddy does not force a cache update. I could submit a patch for the buddylist module that would fix this problem, but that will be low on my list of priorities. For now, it is what it is.
Please test today's Dev release and let me know of any remaining issues.
Thank you so much, Drupalina, for the excellent suggestions and the testing. This is a huge improvement for Affinity.
Best,
sicjoy
#17
#18
Automatically closed -- issue fixed for 2 weeks with no activity.