$contact_email = ('youremail'); 
//contact the webmaster
$LANG["CONTACT_WEBMASTER"] = "Contact Us";
$LANG["WEBMASTER"] = "Contact the webmaster";
$LANG["CONTACT_SHEET"] = "Contact form";
$LANG["EMAIL_WEBMASTER"] = "Send email to";
$LANG["YOUR_EMAIL"] = "Your email";
$LANG["YOUR_ACCOUNT_NAME"] = "Your name";
$LANG["SUBJECT_YOU_MESSAGE"] = "Subject";
$LANG["PLEASE_ON_NOT_ABUSE_MESSAGE"] = "(Please don't choose <b>Yes</b> if isn't really a emergency)";
$LANG["YOUR_MESSAGE_IS_IT_URGENT"] = "It is urgent ?";
$LANG["YOUR_MESSAGE"] = "Your message";
$LANG["REQUIRED_FIELDS"] = "Required fields!";
$LANG["TRANSFERRED_TO_WEBMASTER"] = "Your message has been sent to the webmaster!";
$LANG["ALL_FIELDS"] = "You must complete all required fields!";
ALTER TABLE torrents ADD `recommended` enum('yes','no') NOT NULL default 'no';
In torrents-edit.php
if ($row["external"] != "yes" && $CURUSER["edit_torrents"] == "yes"){
echo "<tr><td class='table_col1' align='right'><b>".T_("FREE_LEECH").": </b></td><td class='table_col2'><input type="checkbox" name="freeleech"" . (($row["freeleech"] == "1") ? " checked="checked"" : "" ) . " value="1" />".T_("FREE_LEECH_MSG")."<br /></td></tr>";
}
Below, add:
if(get_user_class($CURUSER) > 6){
echo "<tr><td align=right><b>Recommended: </b></td><td><input type='checkbox' name='recommended'" . (($row["recommended"] == "yes") ? " checked='checked'" : "" ) . " value='yes' />";
}
Find:
$updateset[] = "freeleech = '".$_POST["freeleech"]."'";
Below, add:
if(get_user_class($CURUSER) > 6){
if ($_POST["recommended"] == "yes")
$updateset[] = "recommended = 'yes'";
else
$updateset[] = "recommended = 'no'";
}
In index.php
Find:
stdhead(T_("HOME"));
Below, add:
//===| Start Recommended Torrents |===//
begin_frame("Recommended Torrents");
$rec = SQL_Query_exec("SELECT id, name, added, image1, seeders, leechers, times_completed FROM torrents WHERE banned ='no' AND visible='yes' AND recommended='yes' ORDER BY torrents.id DESC LIMIT 5");
if (mysql_num_rows($rec) > 0) {
print("<table align=center cellpadding=0 cellspacing=0 width=100% border=0><tr>");
while ($row2 = mysql_fetch_array($rec, MYSQL_NUM)) {
$tor = $row2['0'];
$altname = $row2['1'];
$where = "WHERE banned = 'no' AND visible='yes' AND torrents.id='$tor'";
$res = SQL_Query_exec("SELECT torrents.id, torrents.image1, torrents.image2, torrents.added, torrents.added, torrents.seeders, torrents.leechers, torrents.times_completed, categories.name AS cat_name FROM torrents LEFT JOIN categories ON torrents.category = categories.id $where");
$row = mysql_fetch_array($res);
$cat = $row['cat_name'];
$img1 = "<a href=torrents-details.php?id=$row[id]'><img border='0' src='uploads/images/$row[image1]' title="$altname | $cat" width=150 height=210></a>
<div style='margin-top:3px; font: Arial 11px'>
<img src=images/check.png height='11' title='Completed' border=0> <font color=#0080FF><b>".$row['times_completed']."</b></font> |
<img src=images/arrow_up.gif height='11' title='Seeders' border=0> <font color=#00AA00><b>".$row['seeders']."</b></font> |
<img src=images/arrow_down.gif height='11' title='Leechers' border=0> <font color=#FF0000><b>".$row['leechers']."</b></font>
</div>";
if ($row["image1"] != ""){
print("<td align=center>".$img1."</td>");
}
}
print("</tr></table>");
}
end_frame();
//===| End Recommended Torrents |===//
$xres = SQL_Query_exec("SELECT rating, added FROM ratings WHERE torrent = $id AND user = " . $CURUSER["id"]);
Please to remarks this part:
AND user = " . $CURUSER["id"]
$rres = SQL_Query_exec("SELECT rating FROM ratings WHERE torrent = $id");
$rrow = mysql_fetch_assoc($rres);
if (($rrow) && (get_user_class() >= 5 )) {
print("<div style='margin-bottom:3px'>");
print("<table><tr><td><font size=2>[<a href="javascript:void(0);" onclick="window.open('/ratings.php?id=$id', 'mywindow4', 'width=300, height=580, menubar=no, toolbar=no, scrollbars=yes');"><b>See Votes</b></a>]</font></td></tr></table>");
print("</div>");
}
<td align="center"><a href=upload-bonus.php><img src="images/admin/upload-manager.png" border=0 width=32 height=32><br />Upload Manager</a><br /></td>

".class_user($sd)."with:".$sd."
<?php
require_once("backend/functions.php");
dbconn();
if (get_user_class() < 5)
show_error_msg(T_("ERROR"), T_("SORRY_NO_RIGHTS_TO_ACCESS"), 1);
if (!isset($CURUSER))
show_error_msg(T_("ERROR"), "Not logged in", 1);
$id = 0+$_GET['id'];
$reset = $_GET['reset'];
if($reset == "yes")
{
$res = SQL_Query_exec("DELETE FROM ratings WHERE torrent = $id");
SQL_Query_exec("UPDATE torrents SET numratings = 0, ratingsum = 0 WHERE id = $id");
}
$delete = $_GET['del'];
if(($delete == "yes")&&(get_user_class() >= 6))
{
$rate = 0+$_GET['rate'];
$ratid = 0+$_GET['rat'];
$res = SQL_Query_exec("DELETE FROM ratings WHERE torrent = $id AND user = $ratid ");
SQL_Query_exec("UPDATE torrents SET numratings = numratings - 1, ratingsum = ratingsum - $rate WHERE id = $id");
}
$s = "<br /><table class=table_table align=center width=80% border="0" cellspacing=0 cellpadding="5">n";
$subres = SQL_Query_exec("SELECT * FROM ratings WHERE torrent = $id ORDER BY user");
if(get_user_class() >= 6)
$del1 = "
<td class=table_head align=center>Delete</td>";
$s.="<tr>
<td class=table_head>User</td>
<td class=table_head align=center>Rating</td>
".$del1."</tr>n";
while ($subrow = mysql_fetch_array($subres)) {
$ratingid=$subrow["user"];
$sd=SQL_Query_exec("SELECT username FROM users WHERE id=$ratingid");
$fetched_result = mysql_fetch_array($sd);
$sd = $fetched_result['username'];
$rate = $subrow["rating"];
if(get_user_class() >= 6)
$del2 = "
<td class=table_col1 align=center>[<a href='ratings.php?del=yes&rat=".$ratingid."&id=".$id."&rate=".$rate."'>Delete</a>]</td>";
$s .= "<tr>
<td class=table_col1><a href=account-details.php?id=$ratingid><b>".class_user($sd)."</b></a></td>
<td class=table_col2 align="center"><b>" . $subrow["rating"] . "</b></td>
".$del2."</tr>n";
}
$s .= "</table>n";
$th = @mysql_fetch_array(@sql_query_exec("select uri from stylesheets where id=" . $CURUSER["stylesheet"])) or die(mysql_error());
if ($th)
$THEME = $th[uri];
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
<title>Ratings</title>
<link rel="stylesheet" type="text/css" href="<?php echo $site_config['SITEURL'];?>/themes/<?php echo $THEME;?>/theme.css" />
</head>
<body>
<?php
if (get_user_class() >= 6)
print("<div style='margin-top:15px' align=center>[<a href=ratings.php?reset=yes&id=".$id."><font size=2><b>Reset Ratings</b></a>]</div>");
echo $s;
?>
</body>
</html>
In torrents-details.php after this code:
echo "</table></fieldset><br /><br />";
add this one:
$rres = SQL_Query_exec("SELECT rating FROM ratings WHERE torrent = $id");
$rrow = mysql_fetch_assoc($rres);
if (($rrow) && (get_user_class() >= 5 )) {
print("<div style='margin-bottom:3px'>");
print("<table><tr><td><font size=2>[<a href="javascript:void(0);" onclick="window.open('/ratings.php?id=$id', 'mywindow4', 'width=300, height=580, menubar=no, toolbar=no, scrollbars=yes');"><b>See Votes</b></a>]</font></td></tr></table>");
print("</div>");
}
The new window that displays members votes is associated with the current theme.
But, if the "Body" code of theme.css has no defined colors or has nothing defined:
BODY {}
the background will be white. So you need to define in "Body" code at least 2 colors, something like that:
BODY {
color: #2A2A2A;
background-color: #D4D7D5;
}
for the white themes, or:
BODY {
color: #CBCBCB;
background-color: #151515;
}
for the black ones.
The best is to copy the color codes of the "Shoutbox" code (color and background-color).
I use Class Colors Function: ".class_user($sd)."
with:
".$sd."