The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Rebuild Reputation in Cron?
I already created a Cron job to set any reputation given longer than 7 days ago to 0. It works, but when the reputation is set to 0, it still shows up as a higher number on their profile.
Rebuilding the reputation fixes it, but I was wondering if I could make that a cron job, and how would I do it? I would like to add it to the end of my "Expire Reputation" job so that every time it sets old reputation to 0, it goes ahead and rebuilds the rep. Any thoughts on how to do this easily? |
#2
|
|||
|
|||
I haven't tried this, I'm just taking a stab at it by looking at the code that adds reputation, but maybe something like this: Before you delete the reputation or set it to 0,
PHP Code:
|
#3
|
|||
|
|||
Just out of curiosity why every 7 days you kill every one's rep? To some rep is a flag they look at to see who is most active and giving good answers to questions.
If you flush the rep why bother to have it enabled? |
#4
|
|||
|
|||
It's just a more competitive system of reputation to prevent people from stacking up huge amounts of reputation and then logging off for months and still holding the most reputation. For example, say on day 1 they get 5 rep. Day 2, they get 5 rep. At day 7, they are left with 5 rep total instead of 10. It's to make reputation more competitive. The users try to get as much reputation as they can day by day instead of overall.
Quote:
|
#5
|
|||
|
|||
Well, like I said above I haven't tried it, but I got this from the code where the reputation is increased if someone clicks on the icon, but changed it to decrease instead. You're setting the row in the reputation table to 0? Then you need to update the user row as well, I think.
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|