mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-14 20:40:49 +08:00
fix warning
This commit is contained in:
47
details.php
47
details.php
@@ -26,26 +26,26 @@ if (!$row)
|
||||
elseif ($row['banned'] == 'yes' && get_user_class() < $seebanned_class)
|
||||
permissiondenied();
|
||||
else {
|
||||
if ($_GET["hit"]) {
|
||||
if (!empty($_GET["hit"])) {
|
||||
sql_query("UPDATE torrents SET views = views + 1 WHERE id = $id");
|
||||
}
|
||||
|
||||
if (!isset($_GET["cmtpage"])) {
|
||||
stdhead($lang_details['head_details_for_torrent']. "\"" . $row["name"] . "\"");
|
||||
|
||||
if ($_GET["uploaded"])
|
||||
if (!empty($_GET["uploaded"]))
|
||||
{
|
||||
print("<h1 align=\"center\">".$lang_details['text_successfully_uploaded']."</h1>");
|
||||
print("<p>".$lang_details['text_redownload_torrent_note']."</p>");
|
||||
header("refresh: 1; url=download.php?id=$id");
|
||||
//header("refresh: 1; url=getimdb.php?id=$id&type=1");
|
||||
}
|
||||
elseif ($_GET["edited"]) {
|
||||
elseif (!empty($_GET["edited"])) {
|
||||
print("<h1 align=\"center\">".$lang_details['text_successfully_edited']."</h1>");
|
||||
if (isset($_GET["returnto"]))
|
||||
print("<p><b>".$lang_details['text_go_back'] . "<a href=\"".htmlspecialchars($_GET["returnto"])."\">" . $lang_details['text_whence_you_came']."</a></b></p>");
|
||||
}
|
||||
$sp_torrent = get_torrent_promotion_append($row[sp_state],'word');
|
||||
$sp_torrent = get_torrent_promotion_append($row['sp_state'],'word');
|
||||
|
||||
$s=htmlspecialchars($row["name"]).($sp_torrent ? " ".$sp_torrent : "");
|
||||
print("<h1 align=\"center\" id=\"top\">".$s."</h1>\n");
|
||||
@@ -86,27 +86,28 @@ else {
|
||||
|
||||
$size_info = "<b>".$lang_details['text_size']."</b>" . mksize($row["size"]);
|
||||
$type_info = " <b>".$lang_details['row_type'].":</b> ".$row["cat_name"];
|
||||
$source_info = $medium_info = $codec_info = $audiocodec_info = $standard_info = $processing_info = $team_info = '';
|
||||
if (isset($row["source_name"]))
|
||||
$source_info = " <b>".$lang_details['text_source']." </b>".$row[source_name];
|
||||
$source_info = " <b>".$lang_details['text_source']." </b>".$row['source_name'];
|
||||
if (isset($row["medium_name"]))
|
||||
$medium_info = " <b>".$lang_details['text_medium']." </b>".$row[medium_name];
|
||||
$medium_info = " <b>".$lang_details['text_medium']." </b>".$row['medium_name'];
|
||||
if (isset($row["codec_name"]))
|
||||
$codec_info = " <b>".$lang_details['text_codec']." </b>".$row[codec_name];
|
||||
$codec_info = " <b>".$lang_details['text_codec']." </b>".$row['codec_name'];
|
||||
if (isset($row["standard_name"]))
|
||||
$standard_info = " <b>".$lang_details['text_stardard']." </b>".$row[standard_name];
|
||||
$standard_info = " <b>".$lang_details['text_stardard']." </b>".$row['standard_name'];
|
||||
if (isset($row["processing_name"]))
|
||||
$processing_info = " <b>".$lang_details['text_processing']." </b>".$row[processing_name];
|
||||
$processing_info = " <b>".$lang_details['text_processing']." </b>".$row['processing_name'];
|
||||
if (isset($row["team_name"]))
|
||||
$team_info = " <b>".$lang_details['text_team']." </b>".$row[team_name];
|
||||
$team_info = " <b>".$lang_details['text_team']." </b>".$row['team_name'];
|
||||
if (isset($row["audiocodec_name"]))
|
||||
$audiocodec_info = " <b>".$lang_details['text_audio_codec']." </b>".$row[audiocodec_name];
|
||||
$audiocodec_info = " <b>".$lang_details['text_audio_codec']." </b>".$row['audiocodec_name'];
|
||||
|
||||
tr($lang_details['row_basic_info'], $size_info.$type_info.$source_info . $medium_info. $codec_info . $audiocodec_info. $standard_info . $processing_info . $team_info, 1);
|
||||
if ($CURUSER["downloadpos"] != "no")
|
||||
$download = "<a title=\"".$lang_details['title_download_torrent']."\" href=\"download.php?id=".$id."\"><img class=\"dt_download\" src=\"pic/trans.gif\" alt=\"download\" /> <b><font class=\"small\">".$lang_details['text_download_torrent']."</font></b></a> | ";
|
||||
else $download = "";
|
||||
|
||||
tr($lang_details['row_action'], $download. ($owned == 1 ? "<$editlink><img class=\"dt_edit\" src=\"pic/trans.gif\" alt=\"edit\" /> <b><font class=\"small\">".$lang_details['text_edit_torrent'] . "</font></b></a> | " : ""). (get_user_class() >= $askreseed_class && $row[seeders] == 0 ? "<a title=\"".$lang_details['title_ask_for_reseed']."\" href=\"takereseed.php?reseedid=$id\"><img class=\"dt_reseed\" src=\"pic/trans.gif\" alt=\"reseed\"> <b><font class=\"small\">".$lang_details['text_ask_for_reseed'] ."</font></b></a> | " : "") . "<a title=\"".$lang_details['title_report_torrent']."\" href=\"report.php?torrent=$id\"><img class=\"dt_report\" src=\"pic/trans.gif\" alt=\"report\" /> <b><font class=\"small\">".$lang_details['text_report_torrent']."</font></b></a>", 1);
|
||||
tr($lang_details['row_action'], $download. ($owned == 1 ? "<$editlink><img class=\"dt_edit\" src=\"pic/trans.gif\" alt=\"edit\" /> <b><font class=\"small\">".$lang_details['text_edit_torrent'] . "</font></b></a> | " : ""). (get_user_class() >= $askreseed_class && $row['seeders'] == 0 ? "<a title=\"".$lang_details['title_ask_for_reseed']."\" href=\"takereseed.php?reseedid=$id\"><img class=\"dt_reseed\" src=\"pic/trans.gif\" alt=\"reseed\"> <b><font class=\"small\">".$lang_details['text_ask_for_reseed'] ."</font></b></a> | " : "") . "<a title=\"".$lang_details['title_report_torrent']."\" href=\"report.php?torrent=$id\"><img class=\"dt_report\" src=\"pic/trans.gif\" alt=\"report\" /> <b><font class=\"small\">".$lang_details['text_report_torrent']."</font></b></a>", 1);
|
||||
|
||||
// ---------------- start subtitle block -------------------//
|
||||
$r = sql_query("SELECT subs.*, language.flagpic, language.lang_name FROM subs LEFT JOIN language ON subs.lang_id=language.id WHERE torrent_id = " . sqlesc($row["id"]). " ORDER BY subs.lang_id ASC") or sqlerr(__FILE__, __LINE__);
|
||||
@@ -154,7 +155,7 @@ else {
|
||||
|
||||
if ($CURUSER['showdescription'] != 'no' && !empty($row["descr"])){
|
||||
$torrentdetailad=$Advertisement->get_ad('torrentdetail');
|
||||
tr("<a href=\"javascript: klappe_news('descr')\"><span class=\"nowrap\"><img class=\"minus\" src=\"pic/trans.gif\" alt=\"Show/Hide\" id=\"picdescr\" title=\"".$lang_detail['title_show_or_hide']."\" /> ".$lang_details['row_description']."</span></a>", "<div id='kdescr'>".($Advertisement->enable_ad() && $torrentdetailad ? "<div align=\"left\" style=\"margin-bottom: 10px\" id=\"ad_torrentdetail\">".$torrentdetailad[0]."</div>" : "").format_comment($row["descr"])."</div>", 1);
|
||||
tr("<a href=\"javascript: klappe_news('descr')\"><span class=\"nowrap\"><img class=\"minus\" src=\"pic/trans.gif\" alt=\"Show/Hide\" id=\"picdescr\" title=\"".($lang_details['title_show_or_hide'] ?? '')."\" /> ".$lang_details['row_description']."</span></a>", "<div id='kdescr'>".($Advertisement->enable_ad() && $torrentdetailad ? "<div align=\"left\" style=\"margin-bottom: 10px\" id=\"ad_torrentdetail\">".$torrentdetailad[0]."</div>" : "").format_comment($row["descr"])."</div>", 1);
|
||||
}
|
||||
|
||||
if (get_user_class() >= $viewnfo_class && $CURUSER['shownfo'] != 'no' && $row["nfosz"] > 0){
|
||||
@@ -162,7 +163,7 @@ else {
|
||||
$nfo = code($row["nfo"], $view == "magic");
|
||||
$Cache->cache_value('nfo_block_torrent_id_'.$id, $nfo, 604800);
|
||||
}
|
||||
tr("<a href=\"javascript: klappe_news('nfo')\"><img class=\"plus\" src=\"pic/trans.gif\" alt=\"Show/Hide\" id=\"picnfo\" title=\"".$lang_detail['title_show_or_hide']."\" /> ".$lang_details['text_nfo']."</a><br /><a href=\"viewnfo.php?id=".$row[id]."\" class=\"sublink\">". $lang_details['text_view_nfo']. "</a>", "<div id='knfo' style=\"display: none;\"><pre style=\"font-size:10pt; font-family: 'Courier New', monospace;\">".$nfo."</pre></div>\n", 1);
|
||||
tr("<a href=\"javascript: klappe_news('nfo')\"><img class=\"plus\" src=\"pic/trans.gif\" alt=\"Show/Hide\" id=\"picnfo\" title=\"".$lang_details['title_show_or_hide']."\" /> ".$lang_details['text_nfo']."</a><br /><a href=\"viewnfo.php?id=".$row[id]."\" class=\"sublink\">". $lang_details['text_view_nfo']. "</a>", "<div id='knfo' style=\"display: none;\"><pre style=\"font-size:10pt; font-family: 'Courier New', monospace;\">".$nfo."</pre></div>\n", 1);
|
||||
}
|
||||
|
||||
if ($imdb_id && $showextinfo['imdb'] == 'yes' && $CURUSER['showimdb'] != 'no')
|
||||
@@ -345,7 +346,7 @@ else {
|
||||
|
||||
$Cache->add_whole_row();
|
||||
print("<tr>");
|
||||
print("<td class=\"rowhead\"><a href=\"javascript: klappe_ext('imdb')\"><span class=\"nowrap\"><img class=\"minus\" src=\"pic/trans.gif\" alt=\"Show/Hide\" id=\"picimdb\" title=\"".$lang_detail['title_show_or_hide']."\" /> ".$lang_details['text_imdb'] . $lang_details['row_info'] ."</span></a><div id=\"posterimdb\">". $smallth."</div></td>");
|
||||
print("<td class=\"rowhead\"><a href=\"javascript: klappe_ext('imdb')\"><span class=\"nowrap\"><img class=\"minus\" src=\"pic/trans.gif\" alt=\"Show/Hide\" id=\"picimdb\" title=\"".$lang_details['title_show_or_hide']."\" /> ".$lang_details['text_imdb'] . $lang_details['row_info'] ."</span></a><div id=\"posterimdb\">". $smallth."</div></td>");
|
||||
$Cache->end_whole_row();
|
||||
$Cache->add_row();
|
||||
$Cache->add_part();
|
||||
@@ -410,15 +411,15 @@ else {
|
||||
}
|
||||
|
||||
if (isset($copy_row["source_name"]))
|
||||
$other_source_info = $copy_row[source_name].", ";
|
||||
$other_source_info = $copy_row['source_name'].", ";
|
||||
if (isset($copy_row["medium_name"]))
|
||||
$other_medium_info = $copy_row[medium_name].", ";
|
||||
$other_medium_info = $copy_row['medium_name'].", ";
|
||||
if (isset($copy_row["codec_name"]))
|
||||
$other_codec_info = $copy_row[codec_name].", ";
|
||||
$other_codec_info = $copy_row['codec_name'].", ";
|
||||
if (isset($copy_row["standard_name"]))
|
||||
$other_standard_info = $copy_row[standard_name].", ";
|
||||
$other_standard_info = $copy_row['standard_name'].", ";
|
||||
if (isset($copy_row["processing_name"]))
|
||||
$other_processing_info = $copy_row[processing_name].", ";
|
||||
$other_processing_info = $copy_row['processing_name'].", ";
|
||||
|
||||
$sphighlight = get_torrent_bg_color($copy_row['sp_state']);
|
||||
$sp_info = get_torrent_promotion_append($copy_row['sp_state']);
|
||||
@@ -432,7 +433,7 @@ else {
|
||||
"</tr>\n";
|
||||
}
|
||||
$s .= "</table>\n";
|
||||
tr("<a href=\"javascript: klappe_news('othercopy')\"><span class=\"nowrap\"><img class=\"".($copies_count > 5 ? "plus" : "minus")."\" src=\"pic/trans.gif\" alt=\"Show/Hide\" id=\"picothercopy\" title=\"".$lang_detail['title_show_or_hide']."\" /> ".$lang_details['row_other_copies']."</span></a>", "<b>".$copies_count.$lang_details['text_other_copies']." </b><br /><div id='kothercopy' style=\"".($copies_count > 5 ? "display: none;" : "display: block;")."\">".$s."</div>",1);
|
||||
tr("<a href=\"javascript: klappe_news('othercopy')\"><span class=\"nowrap\"><img class=\"".($copies_count > 5 ? "plus" : "minus")."\" src=\"pic/trans.gif\" alt=\"Show/Hide\" id=\"picothercopy\" title=\"".$lang_details['title_show_or_hide']."\" /> ".$lang_details['row_other_copies']."</span></a>", "<b>".$copies_count.$lang_details['text_other_copies']." </b><br /><div id='kothercopy' style=\"".($copies_count > 5 ? "display: none;" : "display: block;")."\">".$s."</div>",1);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -505,7 +506,7 @@ else {
|
||||
|
||||
tr($lang_details['row_health'], $health, 1);*/
|
||||
tr("<span id=\"seeders\"></span><span id=\"leechers\"></span>".$lang_details['row_peers']."<br /><span id=\"showpeer\"><a href=\"javascript: viewpeerlist(".$row['id'].");\" class=\"sublink\">".$lang_details['text_see_full_list']."</a></span><span id=\"hidepeer\" style=\"display: none;\"><a href=\"javascript: hidepeerlist();\" class=\"sublink\">".$lang_details['text_hide_list']."</a></span>", "<div id=\"peercount\"><b>".$row['seeders'].$lang_details['text_seeders'].add_s($row['seeders'])."</b> | <b>".$row['leechers'].$lang_details['text_leechers'].add_s($row['leechers'])."</b></div><div id=\"peerlist\"></div>" , 1);
|
||||
if ($_GET['dllist'] == 1)
|
||||
if (isset($_GET['dllist']) && $_GET['dllist'] == 1)
|
||||
{
|
||||
$scronload = "viewpeerlist(".$row['id'].")";
|
||||
|
||||
@@ -562,7 +563,7 @@ if ($CURUSER['showcomment'] != 'no'){
|
||||
{
|
||||
print("<br /><br />");
|
||||
print("<h1 align=\"center\" id=\"startcomments\">" .$lang_details['h1_user_comments'] . "</h1>\n");
|
||||
list($pagertop, $pagerbottom, $limit) = pager(10, $count, "details.php?id=$id&cmtpage=1&", array(lastpagedefault => 1), "page");
|
||||
list($pagertop, $pagerbottom, $limit) = pager(10, $count, "details.php?id=$id&cmtpage=1&", array('lastpagedefault' => 1), "page");
|
||||
|
||||
$subres = sql_query("SELECT id, text, user, added, editedby, editdate FROM comments WHERE torrent = $id ORDER BY id $limit") or sqlerr(__FILE__, __LINE__);
|
||||
$allrows = array();
|
||||
|
||||
Reference in New Issue
Block a user