News:

Wondering if this will always be free?  See why free is better.

Main Menu

Advanced Reputation System

Started by Fustrate, March 25, 2008, 12:51:10 PM

Previous topic - Next topic

Spoogs


Dustin

Hello -

I'm running SMF 1.1.11 with ARS and was wondering if there was a way to have the Rep Box open within the post it was clicked on instead of at the very top of the thread. thank you

Gepard

#2102
I'm using this mod with 2.0 RC3 and karmaMaxPerDay setting doesn't seem to work.

Description is
QuoteHow many times a day can a person give reputation?

Code processing this setting is as follows:
// Used up all of their $modSettings['karmaMaxPerDay'] ?
if (!empty($modSettings['karmaMaxPerDay']) && ($modSettings['karmaMaxPerDay'] > 0))
{
// Find out if this user has done this in the past 24 hours.
$request = $smcFunc['db_query']('', '
SELECT log_time
FROM {db_prefix}log_karma
WHERE id_executor = {int:current_member}
AND log_time >= {int:yesterday}',
array(
'current_member' => $user_info['id'],
'yesterday' => $hoursAgo,
)
);

if ($smcFunc['db_num_rows']($request) >= $modSettings['karmaMaxPerDay']){ // but why would they be over?
$smcFunc['db_free_result']($request);
fatal_lang_error('karma_maxed_out', false, array($modSettings['karmaMaxPerDay']));
}

$smcFunc['db_free_result']($request);
}


I'm not familiar enough with SMF internals, like DB functions, so I can't see anything wrong here. Strangely enough it works if I set karmaMaxPerDay to 1. But if I put any number greater than 1, it just doesn't work (I can change reputation as if there was no daily limit).

I suppose it has smth to do wrong number of rows returned, but that's just a guess.

Karma log works fine, so it's not log's fault.

BTW. What are 'Description' and 'link' columns in '{prefix}_log_karma' table? (Nvm, these are leftovers after Karma Description Mod)

EDIT:
Some insights:
- karmaMaxPerDay gets ignored only with JS/AJAX enabled; if I disable JS (for example with NoScript FF plugin), I get the karma_maxed_out error message.
- the 1.8.1 package for 2.0 has a bug: german template mod file affects english template files (due to incorrect names, copypasted probably)
- with karmaWaitTime enabled (hours between reputation actions), you get a karma_please_wait error message if you try to make another karma action within the time limit; ARS gives user approximate minutes until they can make another action, but it's wrong, because ARS queries for the first (oldest) action, but it should query for the last (most recent) action

TurdS

I'm also having a problem with Reputation Power showing anything other than 0, nor is it showing anything other than 1 bar (icon), on a user's post even though they have rep. I'm using SMF 2.0 RC3 and v1.8.1 of the mod. Some one said they had the same problem, and that they solved it but didn't state how.

Spoogs


TurdS


THE BRA1N

I updated the mod as well as the board from RC2 to RC3 and after that everyone's logs got wiped out to "You haven't sent or received any reputation!"

Is there a way to restore the logs short of downgrading back to RC2? 

Fustrate

Steven Hoffman
Former Team Member, 2009-2012


Babalui

Regarding rep power bar (dark green / light green)...

Any way to change how it is displayed?
Say, dark green goes up to 10 bars, then changes to 1 dark and light greens are added up to 10, then changes to 2 dark and so on, 10 in total in each case.
Or, dark green goes up to 5-10, then changes to light green that go up to 5-10, then to gold that go up to 5-10, and so on...

thanks in advance

rdawg

Hello, im curious about something, please excuse me if it is posted, i did a search on this topic and didnt find it.

I would like to know if the reputation that the users give to each other should affect the reputation counter ?

I see that when they post the counter increments as it is defined on the setting, if they create a topic it also increments.

But when i give good reputation it shows on their profile reputation section but the counter does not increment, is this correct?

I thought that this mod was about users giving points to each other not only by posts/topics.

Thank you :=)

Neo_TE


I use "SMF 2.0 RC3" and I see the following errors in the error log even though the guests cannot see the HEART ICON which is used to modify the karma and as per the permissions set in the forums, guests cannot modify the karma.


/forum/index.php?action=modifykarma
8: Undefined index: m
File: /home/zzzz/public_html/forums/Sources/Karma.php
Line: 234

/forum/index.php?action=modifykarma
8: Undefined index: uid
File: /home/zzzz/public_html/forums/Sources/Karma.php
Line: 233

The following are the codes in lines 233,234 & 235 respectively.
    // These _must_ be numbers, no matter what.
    $uid = (int) $_POST['uid'];
    $message_id = (int) $_POST['m'];
    $topic_id = (int) $_POST['topic'];


Any help/clarification would be appreciated. Thanks. :)

Neo_TE

Quote from: rdawg on September 08, 2010, 02:17:45 PM
Hello, im curious about something, please excuse me if it is posted, i did a search on this topic and didnt find it.

I would like to know if the reputation that the users give to each other should affect the reputation counter ?

I see that when they post the counter increments as it is defined on the setting, if they create a topic it also increments.

But when i give good reputation it shows on their profile reputation section but the counter does not increment, is this correct?

I thought that this mod was about users giving points to each other not only by posts/topics.

Thank you :=)

when you give good reputation the counter will increase. check properly. :)

Neo_TE

Quote from: Babalui on September 07, 2010, 01:29:38 AM
Regarding rep power bar (dark green / light green)...

Any way to change how it is displayed?
Say, dark green goes up to 10 bars, then changes to 1 dark and light greens are added up to 10, then changes to 2 dark and so on, 10 in total in each case.
Or, dark green goes up to 5-10, then changes to light green that go up to 5-10, then to gold that go up to 5-10, and so on...

thanks in advance
you can do that but you need to upload images of what you need and also change the coding (bit hard but possible) to achieve that.

Babalui

Quote from: Neo_TE on September 16, 2010, 05:51:43 AM
Quote from: Babalui on September 07, 2010, 01:29:38 AM
Regarding rep power bar (dark green / light green)...

Any way to change how it is displayed?
Say, dark green goes up to 10 bars, then changes to 1 dark and light greens are added up to 10, then changes to 2 dark and so on, 10 in total in each case.
Or, dark green goes up to 5-10, then changes to light green that go up to 5-10, then to gold that go up to 5-10, and so on...

thanks in advance
you can do that but you need to upload images of what you need and also change the coding (bit hard but possible) to achieve that.

I see, thanks.
Well, that a bit over my head, but it would be nice to introduce that coding, cos I have rather small community, where best rep is +3784, 10th rep is +949, and 20th rep is +384.
With current options at hand, I cannot set up rep bars to represent over that range. Those with small rep are having too small bars, and those with higher rep are running out of space to display bars.
If I set up highest ranking to show all bars, then those with lower ranking will look like they are degraded. If I set more then one bars for those under +500, members with large rep are having same number of bars (max).

Babalui

Ehm,
Another kind request :)

I would like to show reputation on memberlist. Anyone done that?

Neo_TE

Quote from: Neo_TE on September 16, 2010, 05:48:04 AM

I use "SMF 2.0 RC3" and I see the following errors in the error log even though the guests cannot see the HEART ICON which is used to modify the karma and as per the permissions set in the forums, guests cannot modify the karma.


/forum/index.php?action=modifykarma
8: Undefined index: m
File: /home/zzzz/public_html/forums/Sources/Karma.php
Line: 234

/forum/index.php?action=modifykarma
8: Undefined index: uid
File: /home/zzzz/public_html/forums/Sources/Karma.php
Line: 233

The following are the codes in lines 233,234 & 235 respectively.
    // These _must_ be numbers, no matter what.
    $uid = (int) $_POST['uid'];
    $message_id = (int) $_POST['m'];
    $topic_id = (int) $_POST['topic'];


Any help/clarification would be appreciated. Thanks. :)

bump. now more similar error shows up in the log. :( please help. :(

Neo_TE

Quote from: Babalui on September 16, 2010, 06:52:43 AM
I see, thanks.
Well, that a bit over my head, but it would be nice to introduce that coding, cos I have rather small community, where best rep is +3784, 10th rep is +949, and 20th rep is +384.
With current options at hand, I cannot set up rep bars to represent over that range. Those with small rep are having too small bars, and those with higher rep are running out of space to display bars.
If I set up highest ranking to show all bars, then those with lower ranking will look like they are degraded. If I set more then one bars for those under +500, members with large rep are having same number of bars (max).
check pm. :)

lhz

When I enter in "View Reputation", it's not well organized. For example, Page 3 shows actions from two days ago and page 2 shows actions from today and yesterday. There is a way to make it more organized (Or sort it in any way I want)?

Babalui

Quote from: Neo_TE on September 21, 2010, 05:08:46 AM
check pm. :)

darn, I tried as you told me, but I'm too... erm.. not enough... youknow... I don't know how exactly :(

I just cannot figure out what piece of code (and how) displays image bars, keep crashing the forum with each try.

I found this piece, but if it is relevant, what to do with it? How to select rep points in a certain range, so I could display a certain pic?

$points = $profile['karmaGood'] - $profile['karmaBad'];
$power = ($points - ($points % $modSettings['karmaBarPower'])) / $modSettings['karmaBarPower'];
$bars = ($points - ($points % $modSettings['karmaBarPoints'])) / $modSettings['karmaBarPoints'];
$bars = $bars == 0 ? 1 : $bars;
$bars = ($bars > $modSettings['karmaMaxBars']) ? $modSettings['karmaMaxBars'] : $bars;
$descriptions = preg_split("/(\r)?\n/", $modSettings['karmaDescriptions']);
$description = $descriptions[$bars - 1];

for($i = 0; $i < $bars; $i++)
$profile['karma_bars'][] = array(
'type' => 'Good_basic',
'desc' => $description
);
if($bars >= $modSettings['karmaSuperBar'])
for($i = ($modSettings['karmaSuperBar'] - 1); $i < $bars; $i++)
$profile['karma_bars'][$i]['type'] = 'Good_super';


Advertisement: