|
Principala » fisiere » Scripturi » TBSource | [ Adauga un material nou ] |
2010-06-20, 10:24 AM | |
Deschideti details.php si Gasiti:
Code $s .= "</td></tr></table>"; tr($tracker_lang['rating'], $s, 1); Mai jos puneti Code ////история оценивания торентов if($CURUSER["class"] > UC_UPLOADER)// показывать только аплоадерам { $r = mysql_query("SELECT ratings.*, users.username, users.id, users.class FROM ratings JOIN users ON users.id=ratings.user WHERE torrent = $id ORDER BY added") or sqlerr(__FILE__,__LINE__); if (mysql_num_rows($r) > 0) { $rates = "<table class=\"main\" border=\"1\" cellspacing=\"0\" cellpadding=\"5\">\n" ."<tr><td class=\"colhead\">Пользователь</td><td class=\"colhead\">Оценка</td><td class=\"colhead\">Дата</td></tr>\n"; while ($a = mysql_fetch_array($r)) { //тут определяем цвета для оценок if ($a["rating"]==1) $ratcolor="<font color=\"red\"><b>1</b></font>"; else if ($a["rating"]==2) $ratcolor="<font color=\"red\"><b>2</b></font>"; else if ($a["rating"]==3) $ratcolor="<font color=\"black\"><b>3</b></font>"; else if ($a["rating"]==4) $ratcolor="<font color=\"blue\"><b>4</b></font>"; else if ($a["rating"]==5) $ratcolor="<font color=\"green\"><b>5</b></font>"; $rates .= "<tr><td style=\"padding: 0px\"><a href=userdetails.php?id=$a[id]>".get_user_class_color($a["class"], $a["username"])."</a></td><td align=\"center\">$ratcolor</td><td align=\"center\">$a[added]</td>\n"; } $rates .= "</table>"; } } if ($rates) print("<tr valign=\"top\"><td class=\"rowhead\">Оценили</td><td align=\"left\"><a href=\"javascript: show_hide('s7')\"><img border=\"0\" src=\"pic/plus.gif\" id=\"pics7\"></a><div id=\"ss7\" style=\"display: none;\">$rates</div></td></tr>\n"); | |
| |
Vizualizari: 1726 | Downloads: | Raging: 0.0/0 |
Total comentarii : 0 | |