go to takecomment.php
find
PHP Code:
$res = sql_query("SELECT name FROM torrents WHERE id = $torrentid") or sqlerr(__FILE__,__LINE__);
and replace with
PHP Code:
$res = sql_query("SELECT name, owner FROM torrents WHERE id = $torrentid") or sqlerr(__FILE__,__LINE__);
find
PHP Code:
UserHandle::KPS("+","0.5",$CURUSER["id"]);
and add above
PHP Code:
$ras = mysql_query("SELECT commentpm FROM users WHERE id = $arr[owner]") or sqlerr(__FILE__,__LINE__);
$arg = mysql_fetch_array($ras);
if($arg['commentpm'] == 'yes')
{
$added = sqlesc(get_date_time());
$subby = sqlesc("Someone has commented on your torrent");
$notifs = sqlesc("You have received a comment on your torrent [url=$DEFAULTBASEURL/details.php?id=$torrentid] " . $arr['name'] . "[/url].");
mysql_query("INSERT INTO messages (sender, receiver, subject, msg, added) VALUES(0, " . $arr['owner'] . ", $subby, $notifs, $added)") or sqlerr(__FILE__, __LINE__);
}
grtzz edgein