View Single Post
  #3  
Old 19th July 2013, 16:22
wMan wMan is offline
Banned
 
Join Date: Feb 2008
P2P
Posts: 1,433
Thumbs up
for comment on torrent = 3 points
in comment.php just after

Code:
@mysql_query("UPDATE torrents SET comments = comments + 1 WHERE id = $torrentid");
add

Code:
   //===add karma
    mysql_query("UPDATE users SET seedbonus = seedbonus+3.0 WHERE id = ".sqlesc($CURUSER["id"])."") or sqlerr(__FILE__, __LINE__);
    //===end
also in comment.php just after

Code:
   mysql_query("UPDATE torrents SET comments = comments - 1 WHERE id = $torrentid");
add
for saying thanks = 2 points - several versions of this adapt yours if you need to
Code:
   //===Remove karma
    mysql_query("UPDATE users SET seedbonus = seedbonus-3.0 WHERE id = ".sqlesc($owner["id"])."") or sqlerr(__FILE__, __LINE__);
    //===end
find in takethankyou.php:

Code:
    mysql_query("UPDATE torrents SET thanks = thanks + 1 WHERE id = ".sqlesc($id)."");
add under it:
Or for putyns new thanks mod find :
Code:
 mysql_query("UPDATE users SET seedbonus = seedbonus+5.0 WHERE id = ".sqlesc($CURUSER["id"])."") or sqlerr(__FILE__, __LINE__);

    print($ajax? json_encode(array('status'=>false,'err'=>$msg)) : $msg);
    }
    }
    }
    break;
    }
many thax
Reply With Quote
The Following User Says Thank You to wMan For This Useful Post:
sushike (4th August 2013)