View Single Post
  #2  
Old 19th July 2013, 16:17
BamBam0077 BamBam0077 is offline
Banned
 
Join Date: Jul 2013
P2P
Posts: 410
Default
for comment on torrent = 3 points
in comment.php just after

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

add

  1. //===add karma
  2. mysql_query("UPDATE users SET seedbonus = seedbonus+3.0 WHERE id = ".sqlesc($CURUSER["id"])."") or sqlerr(__FILE__, __LINE__);
  3. //===end


also in comment.php just after

  1. mysql_query("UPDATE torrents SET comments = comments - 1 WHERE id = $torrentid");

add

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



find in takethankyou.php:


  1. mysql_query("UPDATE torrents SET thanks = thanks + 1 WHERE id = ".sqlesc($id)."");



add under it:

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


  1. print($ajax? json_encode(array('status'=>false,'err'=>$msg)) : $msg);
  2. }
  3. }
  4. }
  5. break;
  6. }
Hope these help you out mate :) if I have miss read please do tell me


Reply With Quote
The Following 2 Users Say Thank You to BamBam0077 For This Useful Post:
ratza (5th August 2013), sushike (4th August 2013)