Thanks works great
//take comment add
if ($_GET["takecomment"] == 'yes'){
$commentbody = $_POST['body'];
if (!$commentbody)
show_error_msg("Error","You did not enter anything!",1);
Below, add:
//PM NOTIF
$res = SQL_Query_exec("SELECT name, owner FROM torrents WHERE id = $id");
$arr = mysql_fetch_array($res);
if($CURUSER['id'] != $arr["owner"]) {
$msg = "You have received a comment on your torrent
."/torrents-details.php?id=$id]" . $arr[name] . "";
SQL_Query_exec("INSERT INTO messages (poster, sender, receiver, msg, added,subject) VALUES('0','0', " . $arr['owner'] . ", " .
sqlesc($msg) . ", '" . get_date_time() . "','New comment!')");
}
//PM NOTIF
[/code]
Quote:by://PM NOTIF
$res = SQL_Query_exec("SELECT name, owner FROM torrents WHERE id = $id");
$arr = mysql_fetch_array($res);
if($CURUSER['id'] != $arr["owner"]) {
$msg = "You have received a comment on your torrent [url=".%20%24site_config%5BsITEURL"]
."/torrents-details.php?id=$id]" . $arr[name] . "[/url]";
SQL_Query_exec("INSERT INTO messages (poster, sender, receiver, msg, added,subject) VALUES('0','0', " . $arr['owner'] . ", " .
sqlesc($msg) . ", '" . get_date_time() . "','New comment!')");
}
//PM NOTIF
Quote://PM NOTIF
$res = SQL_Query_exec("SELECT name, owner FROM torrents WHERE id = $id");
$arr = mysql_fetch_array($res);
if($CURUSER['id'] != $arr["owner"]) {
$msg = "You have received a comment on your torrent [url=".%20%24site_config%5BsITEURL"]
."/torrents-details.php?id=$id]" . $arr[name] . "[/url] the message is
$body";
SQL_Query_exec("INSERT INTO messages (poster, sender, receiver, msg, added,subject) VALUES('0','0', " . $arr['owner'] . ", " .
sqlesc($msg) . ", '" . get_date_time() . "','New comment!')");
}
//PM NOTIF
mysql_querySQL_Query_exec
No users online
Torrents
Members
Online