Uutiset:

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

Main Menu
Advertisement:

Option to not allow smiting one's karma.

Aloittaja Daniel Marquard, toukokuu 09, 2007, 01:02:48 IP

« edellinen - seuraava »

Daniel Marquard

When I enabled "Karma total" for the first time today on one of my forums, I couldn't help but notice that all it did was not display the number of times one was applauded, separate from total smites.

There should be an addition to SMF's karma system that allows for only applauding one's total karma.  This would make so that either a user's reputation is increased by one, or simply disregarded.  There would be no option of smiting one's karma total.

Gary

You could also just remove the smite link out of Display.template.php so people cant do it in the first place.

-ALM
Gary M. Gadsdon
Do NOT PM me unless I say so
War of the Simpsons
Bongo Comics Fan Forum
Youtube Let's Plays

^ YT is changing monetisation policy, help reach 1000 sub threshold.

Daniel Marquard

Lainaus käyttäjältä: ALM - toukokuu 09, 2007, 01:09:14 IP
You could also just remove the smite link out of Display.template.php so people cant do it in the first place.

-ALM

Though possible, one could easily exploit that.

Edit: A look through Karma.php shows no obvious 'smite' action.  Only the following:

Koodi (Karma.php) [Valitse]
// Applauding or smiting?
$dir = $_REQUEST['sa'] != 'applaud' ? -1 : 1;

Exochat

If you go to the Karma Mod on your ADMIN part, it gives you the Applaud and Smite options where you can change them to be whatever you want.

Keep the Applaud as it is but just delete the word Smite and leave it as a blank box.

This then only leaves the Applaud option on peoples posts thus only able to ADD Karma and not remove it.

Hope this helps.

Ken.

Lainaus käyttäjältä: Exochat - toukokuu 10, 2007, 08:59:17 AP
If you go to the Karma Mod on your ADMIN part, it gives you the Applaud and Smite options where you can change them to be whatever you want.

Keep the Applaud as it is but just delete the word Smite and leave it as a blank box.

This then only leaves the Applaud option on peoples posts thus only able to ADD Karma and not remove it.

Hope this helps.

Works for me.  ;D

Daniel Marquard

Lainaus käyttäjältä: Exochat - toukokuu 10, 2007, 08:59:17 AP
If you go to the Karma Mod on your ADMIN part, it gives you the Applaud and Smite options where you can change them to be whatever you want.

Keep the Applaud as it is but just delete the word Smite and leave it as a blank box.

This then only leaves the Applaud option on peoples posts thus only able to ADD Karma and not remove it.

Hope this helps.

Doesn't work for me.  The same could be done by doing what ALM said.  Removing a link or some text does not necessarily stop a user from smiting another user's karma, as the link is still accessible.  If I wanted to remove a link, I wouldn't create a new topic requesting that it be changed.

青山 素子

Try:


// Applauding or smiting?
$dir = $_REQUEST['sa'] != 'applaud' ? 0 : 1;


That should make it so no points are earned or taken on a smite.
Motoko-chan
Director, Simple Machines

Note: Unless otherwise stated, my posts are not representative of any official position or opinion of Simple Machines.


Daniel Marquard

Lainaus käyttäjältä: Motoko-chan - toukokuu 10, 2007, 11:37:58 AP
Try:


// Applauding or smiting?
$dir = $_REQUEST['sa'] != 'applaud' ? 0 : 1;


That should make it so no points are earned or taken on a smite.

Bah, I just did something similar!  It took me some time to figure out that the clause distributes karma +1 for 'sa=applaud' and -1 for absolutely anything else in place of 'applaud'.  For anyone else that would like this changed, make the following edit:

Koodi (Karma.php, find) [Valitse]
   // Applauding or smiting?
   $dir = $_REQUEST['sa'] != 'applaud' ? -1 : 1;


Koodi (Karma.php, replace with) [Valitse]
    // Applaud or DIE!
    $dir = $_REQUEST['sa'] == 'applaud' ? 1 : fatal_error('The smiting of one\'s karma has been disabled. Please report the URL and the location of the link you clicked to the forum\'s administrator.');


Advertisement: