View Full Version : Reputation Click Tracker
tubedogg
12-11-2004, 10:00 PM
(I couldn't think of a good name for this, so there you go...)
This is a relatively simple hack that adds a box to the User CP showing a user how many reputation clicks he has given in the last 24 hours, and how many more he can give, and it also shows this information in a small graph (using the poll images). [see the screenshot]
It requires you to modify one file, one template, and add one template. Instructions are in the file named INSTALL in the ZIP archive attached to this post.
Questions, post em here. Please do not contact me privately about this hack as it will be ignored.
Version History
1.0.1, 12 December 2004 4:25PM EST:
- Fixed small bug (https://vborg.vbsupport.ru/showthread.php?p=581554#post581554) with date display.
1.0.0:
- Initial release.
docvader
12-12-2004, 12:40 AM
Wow. Am I the first? Gosh...
Installed, in a matter of minutes, very easily. Works great! Thanks.
rich
russbo.com
Sadie Frost
12-12-2004, 01:59 AM
Wow. Am I the first? Gosh...
Installed, in a matter of minutes, very easily. Works great! Thanks.
rich
russbo.com
That's great - takes the guesswork out of rep giving :)
yinyang
12-12-2004, 07:28 AM
is there anyway to put this in your postbit? my users would use the rep function more if they see how much they have to give from the forum displays. or can you put it in the navbar area?
sabret00the
12-12-2004, 09:17 AM
nice work :)
Paul M
12-12-2004, 09:54 AM
Cool,
We already display reputation given (https://vborg.vbsupport.ru/showthread.php?t=69296), this looks a nice addition.
ambumann
12-12-2004, 12:18 PM
Thanks for the good work!
n3ol3o
12-12-2004, 02:14 PM
seems to work fine, my members will love you for this- they know and care more about rep than i do!
nighteyes
12-12-2004, 06:17 PM
Nice one ;)
well done! Well done indeed!
nighteyes
12-12-2004, 07:12 PM
A bug? The following was reported by one our members who had exceeded their daily limit...
In the last 24 hours, you have given reputation to 10 posters.
This is the daily limit, so you may not give reputation again until 01-02-1970 01:00 AM.
nighteyes
12-12-2004, 07:22 PM
Just tested this myself (gave reputation to 10 users) and I'm seeing the same message. Any ideas?
tubedogg
12-12-2004, 07:25 PM
A bug? The following was reported by one our members who had exceeded their daily limit...
Easy fix.
In usercp.php find this line:
$earliest = $check['dateline'];
Move it right below $sofar++; so it's above the }, i.e.
$sofar++;
$earliest = $check['dateline'];
}
Change this line:
$nexttime = date($vboptions['dateformat'].' '.$vboptions['timeformat'], ($check['dateline']+86400));
To this:
$nexttime = vbdate($vboptions['dateformat'].' '.$vboptions['timeformat'], ($earliest+86400));
ZIP updated to v1.0.1.
nighteyes
12-12-2004, 07:34 PM
Wow that was very quick :D Implemented those changes and it works perfectly....... thanks alot. Very useful hack.
Bison
12-12-2004, 07:37 PM
Thanks for the fix tubedogg, but I have a question to ask ... isn't this true that admins have no restrictions to giving rep points? If so, then can there be a condition where if this is true, then all that shows up for admins is how many times they have given rep points?
tubedogg
12-12-2004, 08:24 PM
Thanks for the fix tubedogg, but I have a question to ask ... isn't this true that admins have no restrictions to giving rep points? If so, then can there be a condition where if this is true, then all that shows up for admins is how many times they have given rep points?
Yes you're right...admins have no limit. However determining how many times an admin has given reputation could put a lot of load on the server, if the admin has given a lot.
A condition could be used to say "you have no limit", but I'm not sure I'd want to determine the number of times reputation has been given for the above reason.
Bison
12-12-2004, 08:28 PM
Under the current situation, an admin is shown that he has only X amount of times that he can give Rep points. How could I fix it to show that there's no limit?
Erwin
12-12-2004, 08:33 PM
This is great. :) Thanks!
Bison
12-12-2004, 08:48 PM
Correct this if i'm wrong:
<if condition="$bbusergroupid = 6">
<td align="left" valign="top" class="alt1" width="50%">
In the last 24 hours, you have given reputation to <b>$sofar</b> posters.<br />
There is no daily limit for <b>admins</b>, so you may give reputation as often as you like.</td>
</if>
For non-admins:
<if condition="$bbusergroupid != 6">
<td align="left" valign="top" class="alt1" width="50%">
In the last 24 hours, you have given reputation to <b>$sofar</b> posters.<br />
<if condition="$nexttime != 0">
This is the daily limit, so you may not give reputation again until $nexttime.
<else />
You can give reputation to <b>$clicksremain</b> more poster<if condition="$clicksremain > 1">s</if> today.</td>
</if>
Erwin
12-13-2004, 06:27 AM
You might want to add the 'usercp_reptracker' template to the templatecache of usercp.php to save that 1 query. :)
In usercp.php, find:
'usercp_reputationbits'
REPLACE with:
'usercp_reputationbits',
'usercp_reptracker'
Done! :)
Erwin
12-13-2004, 06:28 AM
One suggestion:
Show the reputation giving power as well. :)
docvader
12-13-2004, 03:02 PM
Sure this works correctly? It's not refreshing down to zero on a daily basis (it still holds onto the three reputations I gave out last week (OK, I'm not too generous... LOL)
rich
tubedogg
12-13-2004, 06:17 PM
Sure this works correctly? It's not refreshing down to zero on a daily basis (it still holds onto the three reputations I gave out last week (OK, I'm not too generous... LOL)
rich
The query looks for up to the last X times you've given in the last 24 hours, where X is the daily limit...
AND dateline >= ".(time()-86400)."
Unless time() is malfunctioning on your server, I can't see any reason why it would show 3 that you gave last week.
tubedogg
12-13-2004, 06:18 PM
One suggestion:
Show the reputation giving power as well. :)
Not a bad idea...
I'll be doing an updated version later today or tommorrow that takes this into account, plus the template caching and showing the admin how many times he has given overall.
docvader
12-13-2004, 06:43 PM
Not a bad idea...
I'll be doing an updated version later today or tommorrow that takes this into account, plus the template caching and showing the admin how many times he has given overall.
Time is ok and functioning on my server, but I'm using Mac OSX, Jaguar 10.2 for my operating system. Not sure if the query is hitting it correctly, nor do I know how to check it, LOL.
Bison
12-13-2004, 08:23 PM
Not a bad idea...
I'll be doing an updated version later today or tommorrow that takes this into account, plus the template caching and showing the admin how many times he has given overall.
Thanks Tubedogg! :banana:
trackpads
12-13-2004, 11:19 PM
Kevin thanks!!!
Now get back to work on Hivemail! :-) (I kid I kid!!)
Mark.B
12-18-2004, 04:58 PM
This is still not 100% right.
If you exceed the daily limit, the tracker simply says this:
In the last 24 hours, you have given reputation to 15 posters.
You can give reputation to 0 more poster today
In other words, the condition based around $nexttime is not working, it is not displaying the message about when you can give rep again.
Mark.B
12-18-2004, 05:31 PM
Hmm...fixed this by changing $nexttime != 0 to $nexttime != '0' in the usercp_reptracker template.....
Also noticed the collapse toggle needs fixing as it currently collapses a different table.
In the usercp_reptracker find:
<tbody id="collapseobj_usercp_forums" style="$vbcollapse[collapseobj_usercp_forums]">
Change to:
<tbody id="collapseobj_usercp_tracker" style="$vbcollapse[collapseobj_usercp_tracker]">
Also find code:
<a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('usercp_forums')">
Change to:
<a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('usercp_tracker')">
trackpads
12-18-2004, 10:18 PM
Thanks!
rex_b
12-20-2004, 06:14 PM
nice work.. installed
T3MEDIA
12-20-2004, 08:11 PM
Cool,
We already display reputation given (https://vborg.vbsupport.ru/showthread.php?t=69296), this looks a nice addition.
why cant we get a hack that just makes reps like ebay? you can go on the profile page and leave a rep. you can only vote once on that pertiular user and thats that. other users can view what you said and wala. that what a rep really is. this is more like a post quality checker.
folkish
01-05-2005, 05:19 AM
/me clicks install.
Very useful hack. Great work.
Trisha
01-16-2005, 04:24 PM
installed! it looks and works great! thanks.
Lottis
01-26-2005, 08:04 AM
I still get this message:
In the last 24 hours, you have given reputation to 0 posters.
This is the daily limit, so you may not give reputation again until 01-02-1970 01:00 AM.
Borgs8472
02-08-2005, 06:14 PM
My users can't see the poll images... :(
For some reason in IE only the USERCP page is stretched really wide after installing this hack and the Display reputation giving hack. Don't know which one caused the problem. Firefox and Opera work fine, IE is the only one with the problem. Any ideas?
I just realized it's not only stretched, it doesn't show who gave the reputation or the comment.
LauraFL
02-11-2005, 07:47 PM
I still get this message:
In the last 24 hours, you have given reputation to 0 posters.
This is the daily limit, so you may not give reputation again until 01-02-1970 01:00 AM.
This is exactly what I am getting. Any idea how to fix it?
MAK-upl
02-18-2005, 03:40 PM
coul'd somebody help me with that strange thing in graf ? vb 3,0,6
LauraFL
02-18-2005, 03:57 PM
I still get this message:
In the last 24 hours, you have given reputation to 0 posters.
This is the daily limit, so you may not give reputation again until 01-02-1970 01:00 AM.
Can someone please help me figure out why?
Borgs8472
11-19-2005, 12:29 AM
Now I need this for 3.5....
baronvonwalz
11-28-2005, 01:21 PM
Any news on porting this to vB 3.5?
Borgs8472
12-05-2005, 09:20 PM
^ ^
away loathsome dual!
baronvonwalz
12-06-2005, 04:46 AM
^ ^
away loathsome dual!
Not dual, fellow admin. Get it right.
Borgs8472
12-26-2005, 12:34 PM
Paid to get this done. PM me if you want that hack for just $5
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.