BioTorrents.de’s version of Gazelle
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

user.php 19KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613
  1. <?php
  2. $Orders = ['Time', 'Name', 'Seeders', 'Leechers', 'Snatched', 'Size'];
  3. $Ways = ['DESC' => 'Descending', 'ASC' => 'Ascending'];
  4. // The "order by x" links on columns headers
  5. function header_link($SortKey, $DefaultWay = 'DESC')
  6. {
  7. global $Order, $Way;
  8. if ($SortKey === $Order) {
  9. if ($Way === 'DESC') {
  10. $NewWay = 'ASC';
  11. } else {
  12. $NewWay = 'DESC';
  13. }
  14. } else {
  15. $NewWay = $DefaultWay;
  16. }
  17. return "torrents.php?way=$NewWay&amp;order=$SortKey&amp;" . Format::get_url(array('way','order'));
  18. }
  19. $UserID = $_GET['userid'];
  20. if (!is_number($UserID)) {
  21. error(0);
  22. }
  23. if (!empty($_GET['page']) && is_number($_GET['page']) && $_GET['page'] > 0) {
  24. $Page = $_GET['page'];
  25. $Limit = ($Page - 1) * TORRENTS_PER_PAGE.', '.TORRENTS_PER_PAGE;
  26. } else {
  27. $Page = 1;
  28. $Limit = TORRENTS_PER_PAGE;
  29. }
  30. if (!empty($_GET['order']) && in_array($_GET['order'], $Orders)) {
  31. $Order = $_GET['order'];
  32. } else {
  33. $Order = 'Time';
  34. }
  35. if (!empty($_GET['way']) && array_key_exists($_GET['way'], $Ways)) {
  36. $Way = $_GET['way'];
  37. } else {
  38. $Way = 'DESC';
  39. }
  40. $SearchWhere = [];
  41. if (!empty($_GET['format'])) {
  42. if (in_array($_GET['format'], $Formats)) {
  43. $SearchWhere[] = "t.Format = '".db_string($_GET['format'])."'";
  44. } elseif ($_GET['format'] === 'perfectflac') {
  45. $_GET['filter'] = 'perfectflac';
  46. }
  47. }
  48. # Get release specifics
  49. if (isset($_GET['container']) && in_array($_GET['container'], array_unique(array_merge($Containers, $ContainersGames, $ContainersProt)))) {
  50. $SearchWhere[] = "t.Container = '".db_string($_GET['container'])."'";
  51. }
  52. if (isset($_GET['bitrate']) && in_array($_GET['bitrate'], $Bitrates)) {
  53. $SearchWhere[] = "t.Encoding = '".db_string($_GET['bitrate'])."'";
  54. }
  55. if (isset($_GET['media']) && in_array($_GET['media'], array_unique(array_merge($Media, $MediaManga)))) {
  56. $SearchWhere[] = "t.Media = '".db_string($_GET['media'])."'";
  57. }
  58. if (isset($_GET['codec']) && in_array($_GET['codec'], $Codecs)) {
  59. $SearchWhere[] = "t.Codec = '".db_string($_GET['codec'])."'";
  60. }
  61. if (isset($_GET['audioformat']) && in_array($_GET['audioformat'], $AudioFormats)) {
  62. $SearchWhere[] = "t.AudioFormat = '".db_string($_GET['audioformat'])."'";
  63. }
  64. if (isset($_GET['resolution']) && in_array($_GET['resolution'], $Resolutions)) {
  65. $SearchWhere[] = "t.Resolution = '".db_string($_GET['resolution'])."'";
  66. }
  67. if (isset($_GET['language']) && in_array($_GET['language'], $Languages)) {
  68. $SearchWhere[] = "t.Language = '".db_string($_GET['language'])."'";
  69. }
  70. if (isset($_GET['subbing']) && in_array($_GET['subbing'], $Subbing)) {
  71. $SearchWhere[] = "t.Subbing = '".db_string($_GET['subbing'])."'";
  72. }
  73. if (isset($_GET['censored']) && in_array($_GET['censored'], array(1, 0))) {
  74. $SearchWhere[] = "t.Censored = '".db_string($_GET['censored'])."'";
  75. }
  76. if (!empty($_GET['categories'])) {
  77. $Cats = [];
  78. foreach (array_keys($_GET['categories']) as $Cat) {
  79. if (!is_number($Cat)) {
  80. error(0);
  81. }
  82. $Cats[] = "tg.CategoryID = '".db_string($Cat)."'";
  83. }
  84. $SearchWhere[] = '('.implode(' OR ', $Cats).')';
  85. }
  86. if (!isset($_GET['tags_type'])) {
  87. $_GET['tags_type'] = '1';
  88. }
  89. if (!empty($_GET['tags'])) {
  90. $Tags = explode(',', $_GET['tags']);
  91. $TagList = [];
  92. foreach ($Tags as $Tag) {
  93. $Tag = trim(str_replace('.', '_', $Tag));
  94. if (empty($Tag)) {
  95. continue;
  96. }
  97. if ($Tag[0] === '!') {
  98. $Tag = ltrim(substr($Tag, 1));
  99. if (empty($Tag)) {
  100. continue;
  101. }
  102. $TagList[] = "tg.TagList NOT RLIKE '[[:<:]]".db_string($Tag)."(:[^ ]+)?[[:>:]]'";
  103. } else {
  104. $TagList[] = "tg.TagList RLIKE '[[:<:]]".db_string($Tag)."(:[^ ]+)?[[:>:]]'";
  105. }
  106. }
  107. if (!empty($TagList)) {
  108. if (isset($_GET['tags_type']) && $_GET['tags_type'] !== '1') {
  109. $_GET['tags_type'] = '0';
  110. $SearchWhere[] = '('.implode(' OR ', $TagList).')';
  111. } else {
  112. $_GET['tags_type'] = '1';
  113. $SearchWhere[] = '('.implode(' AND ', $TagList).')';
  114. }
  115. }
  116. }
  117. $SearchWhere = implode(' AND ', $SearchWhere);
  118. if (!empty($SearchWhere)) {
  119. $SearchWhere = " AND $SearchWhere";
  120. }
  121. $User = Users::user_info($UserID);
  122. $Perms = Permissions::get_permissions($User['PermissionID']);
  123. $UserClass = $Perms['Class'];
  124. switch ($_GET['type']) {
  125. case 'snatched':
  126. if (!check_paranoia('snatched', $User['Paranoia'], $UserClass, $UserID)) {
  127. error(403);
  128. }
  129. $Time = 'xs.tstamp';
  130. $UserField = 'xs.uid';
  131. $ExtraWhere = '';
  132. $From = "
  133. xbt_snatched AS xs
  134. JOIN torrents AS t ON t.ID = xs.fid";
  135. break;
  136. case 'seeding':
  137. if (!check_paranoia('seeding', $User['Paranoia'], $UserClass, $UserID)) {
  138. error(403);
  139. }
  140. $Time = '(xfu.mtime - xfu.timespent)';
  141. $UserField = 'xfu.uid';
  142. $ExtraWhere = '
  143. AND xfu.active = 1
  144. AND xfu.Remaining = 0';
  145. $From = "
  146. xbt_files_users AS xfu
  147. JOIN torrents AS t ON t.ID = xfu.fid";
  148. break;
  149. case 'contest':
  150. $Time = 'unix_timestamp(t.Time)';
  151. $UserField = 't.UserID';
  152. $ExtraWhere = "
  153. AND t.ID IN (
  154. SELECT TorrentID
  155. FROM library_contest
  156. WHERE UserID = $UserID
  157. )";
  158. $From = 'torrents AS t';
  159. break;
  160. case 'leeching':
  161. if (!check_paranoia('leeching', $User['Paranoia'], $UserClass, $UserID)) {
  162. error(403);
  163. }
  164. $Time = '(xfu.mtime - xfu.timespent)';
  165. $UserField = 'xfu.uid';
  166. $ExtraWhere = '
  167. AND xfu.active = 1
  168. AND xfu.Remaining > 0';
  169. $From = "
  170. xbt_files_users AS xfu
  171. JOIN torrents AS t ON t.ID = xfu.fid";
  172. break;
  173. case 'uploaded':
  174. if ((empty($_GET['filter']) || $_GET['filter'] !== 'perfectflac') && !check_paranoia('uploads', $User['Paranoia'], $UserClass, $UserID)) {
  175. error(403);
  176. }
  177. $Time = 'unix_timestamp(t.Time)';
  178. $UserField = 't.UserID';
  179. $ExtraWhere = '';
  180. $From = "torrents AS t";
  181. break;
  182. case 'downloaded':
  183. if (!check_perms('site_view_torrent_snatchlist')) {
  184. error(403);
  185. }
  186. $Time = 'unix_timestamp(ud.Time)';
  187. $UserField = 'ud.UserID';
  188. $ExtraWhere = '';
  189. $From = "
  190. users_downloads AS ud
  191. JOIN torrents AS t ON t.ID = ud.TorrentID";
  192. break;
  193. default:
  194. error(404);
  195. }
  196. if (!empty($_GET['filter'])) {
  197. if ($_GET['filter'] === 'perfectflac') {
  198. if (!check_paranoia('perfectflacs', $User['Paranoia'], $UserClass, $UserID)) {
  199. error(403);
  200. }
  201. $ExtraWhere .= " AND t.Format = 'FLAC'";
  202. if (empty($_GET['media'])) {
  203. $ExtraWhere .= "
  204. AND (
  205. t.LogScore = 100 OR
  206. t.Media IN ('Vinyl', 'WEB', 'DVD', 'Soundboard', 'Cassette', 'SACD', 'Blu-ray', 'DAT')
  207. )";
  208. } elseif (strtoupper($_GET['media']) === 'CD' && empty($_GET['log'])) {
  209. $ExtraWhere .= "
  210. AND t.LogScore = 100";
  211. }
  212. } elseif ($_GET['filter'] === 'uniquegroup') {
  213. if (!check_paranoia('uniquegroups', $User['Paranoia'], $UserClass, $UserID)) {
  214. error(403);
  215. }
  216. $GroupBy = 'tg.ID';
  217. }
  218. }
  219. if (empty($GroupBy)) {
  220. $GroupBy = 't.ID';
  221. }
  222. if ((empty($_GET['search']) || trim($_GET['search']) === '')) { // && $Order !== 'Name') {
  223. $SQL = "
  224. SELECT
  225. SQL_CALC_FOUND_ROWS
  226. t.GroupID,
  227. t.ID AS TorrentID,
  228. $Time AS Time,
  229. COALESCE(NULLIF(tg.Name, ''), NULLIF(tg.NameRJ, ''), tg.NameJP) AS Name,
  230. tg.CategoryID
  231. FROM $From
  232. JOIN torrents_group AS tg ON tg.ID = t.GroupID
  233. WHERE $UserField = '$UserID'
  234. $ExtraWhere
  235. $SearchWhere
  236. GROUP BY $GroupBy
  237. ORDER BY $Order $Way
  238. LIMIT $Limit";
  239. } else {
  240. $DB->query("
  241. CREATE TEMPORARY TABLE temp_sections_torrents_user (
  242. GroupID int(10) unsigned not null,
  243. TorrentID int(10) unsigned not null,
  244. Time int(12) unsigned not null,
  245. CategoryID int(3) unsigned,
  246. Seeders int(6) unsigned,
  247. Leechers int(6) unsigned,
  248. Snatched int(10) unsigned,
  249. Name mediumtext,
  250. Size bigint(12) unsigned,
  251. PRIMARY KEY (TorrentID)) CHARSET=utf8");
  252. $DB->query("
  253. INSERT IGNORE INTO temp_sections_torrents_user
  254. SELECT
  255. t.GroupID,
  256. t.ID AS TorrentID,
  257. $Time AS Time,
  258. tg.CategoryID,
  259. t.Seeders,
  260. t.Leechers,
  261. t.Snatched,
  262. CONCAT_WS(' ', GROUP_CONCAT(ag.Name SEPARATOR ' '), ' ', COALESCE(NULLIF(tg.Name,''), NULLIF(tg.NameRJ,''), tg.NameJP), ' ', tg.Year, ' ') AS Name,
  263. t.Size
  264. FROM $From
  265. JOIN torrents_group AS tg ON tg.ID = t.GroupID
  266. LEFT JOIN torrents_artists AS ta ON ta.GroupID = tg.ID
  267. LEFT JOIN artists_group AS ag ON ag.ArtistID = ta.ArtistID
  268. WHERE $UserField = '$UserID'
  269. $ExtraWhere
  270. $SearchWhere
  271. GROUP BY TorrentID, Time");
  272. if (!empty($_GET['search']) && trim($_GET['search']) !== '') {
  273. $Words = array_unique(explode(' ', db_string($_GET['search'])));
  274. }
  275. $SQL = "
  276. SELECT
  277. SQL_CALC_FOUND_ROWS
  278. GroupID,
  279. TorrentID,
  280. Time,
  281. CategoryID
  282. FROM temp_sections_torrents_user";
  283. if (!empty($Words)) {
  284. $SQL .= "
  285. WHERE Name LIKE '%".implode("%' AND Name LIKE '%", $Words)."%'";
  286. }
  287. $SQL .= "
  288. ORDER BY $Order $Way
  289. LIMIT $Limit";
  290. }
  291. $DB->query($SQL);
  292. $GroupIDs = $DB->collect('GroupID');
  293. $TorrentsInfo = $DB->to_array('TorrentID', MYSQLI_ASSOC);
  294. $DB->query('SELECT FOUND_ROWS()');
  295. list($TorrentCount) = $DB->next_record();
  296. $Results = Torrents::get_groups($GroupIDs);
  297. $Action = display_str($_GET['type']);
  298. $User = Users::user_info($UserID);
  299. View::show_header($User['Username']."'s $Action torrents", 'browse');
  300. $Pages = Format::get_pages($Page, $TorrentCount, TORRENTS_PER_PAGE);
  301. ?>
  302. <div class="thin">
  303. <div class="header">
  304. <h2><a href="user.php?id=<?= $UserID ?>"><?= $User['Username'] ?></a><?= "'s $Action torrents" ?>
  305. </h2>
  306. </div>
  307. <div class="box pad">
  308. <form class="search_form" name="torrents" action="" method="get">
  309. <table class="layout">
  310. <!-- Terms -->
  311. <tr>
  312. <td class="label"><strong>Search Terms</strong></td>
  313. <td>
  314. <input type="hidden" name="type"
  315. value="<?= $_GET['type'] ?>" />
  316. <input type="hidden" name="userid"
  317. value="<?= $UserID ?>" />
  318. <input type="search" name="search" size="60"
  319. value="<?php Format::form('search') ?>" />
  320. </td>
  321. </tr>
  322. <!--
  323. Specifics
  324. todo: Make like the Seq/Img Format fields in browse.php
  325. -->
  326. <tr>
  327. <td class="label"><strong>Specifics</strong></td>
  328. <td class="nobr" colspan="3">
  329. <select id="container" name="container" class="ft_container">
  330. <option value="">Format</option>
  331. <?php foreach ($Containers as $Key => $ContainerName) { ?>
  332. <option value="<?= display_str($Key); ?>" <?php Format::selected('container', $Key) ?>><?= display_str($Key); ?>
  333. </option>
  334. <?php } ?>
  335. </select>
  336. <select id="codec" name="codec" class="ft_codec">
  337. <option value="">License</option>
  338. <?php foreach ($Codecs as $CodecName) { ?>
  339. <option value="<?= display_str($CodecName); ?>" <?php Format::selected('codec', $CodecName) ?>><?= display_str($CodecName); ?>
  340. </option>
  341. <?php } ?>
  342. </select>
  343. <select id="resolution" name="resolution" class="ft_resolution">
  344. <option value="">Assembly Level</option>
  345. <?php foreach ($Resolutions as $ResolutionName) { ?>
  346. <option value="<?= display_str($ResolutionName); ?>"
  347. <?php Format::selected('resolution', $ResolutionName) ?>><?= display_str($ResolutionName); ?>
  348. </option>
  349. <?php } ?>
  350. </select>
  351. <select name="media" class="ft_media">
  352. <option value="">Platform</option>
  353. <?php foreach ($Media as $MediaName) { ?>
  354. <option value="<?= display_str($MediaName); ?>" <?php Format::selected('media', $MediaName) ?>><?= display_str($MediaName); ?>
  355. </option>
  356. <?php } ?>
  357. </select>
  358. </td>
  359. </tr>
  360. <!-- Misc -->
  361. <tr>
  362. <td class="label"><strong>Misc</strong></td>
  363. <td class="nobr" colspan="3">
  364. <select name="censored" class="ft_censored">
  365. <option value="3">Alignment</option>
  366. <option value="1" <?Format::selected('censored', 1)?>>Aligned
  367. </option>
  368. <option value="0" <?Format::selected('censored', 0)?>>Not Aligned
  369. </option>
  370. </select>
  371. </td>
  372. </tr>
  373. <!-- Tags -->
  374. <tr>
  375. <td class="label"><strong>Tags</strong></td>
  376. <td>
  377. <input type="search" name="tags" size="60"
  378. value="<?php Format::form('tags') ?>" />&nbsp;
  379. <input type="radio" name="tags_type" id="tags_type0" value="0" <?php Format::selected('tags_type', 0, 'checked') ?>
  380. /><label for="tags_type0"> Any</label>&nbsp;&nbsp;
  381. <input type="radio" name="tags_type" id="tags_type1" value="1" <?php Format::selected('tags_type', 1, 'checked') ?>
  382. /><label for="tags_type1"> All</label><br />
  383. Use !tag to exclude tags
  384. </td>
  385. </tr>
  386. <!-- Order By -->
  387. <tr>
  388. <td class="label"><strong>Order By</strong></td>
  389. <td>
  390. <select name="order" class="ft_order_by">
  391. <?php foreach ($Orders as $OrderText) { ?>
  392. <option value="<?= $OrderText ?>" <?php Format::selected('order', $OrderText) ?>><?= $OrderText ?>
  393. </option>
  394. <?php } ?>
  395. </select>
  396. <select name="way" class="ft_order_way">
  397. <?php foreach ($Ways as $WayKey=>$WayText) { ?>
  398. <option value="<?= $WayKey ?>" <?php Format::selected('way', $WayKey) ?>><?= $WayText ?>
  399. </option>
  400. <?php } ?>
  401. </select>
  402. </td>
  403. </tr>
  404. </table>
  405. <!-- Categories -->
  406. <table class="layout cat_list">
  407. <?php
  408. $x = 0;
  409. reset($Categories);
  410. foreach ($Categories as $CatKey => $CatName) {
  411. if ($x % 7 === 0) {
  412. if ($x > 0) {
  413. ?>
  414. </tr>
  415. <?php
  416. } ?>
  417. <tr>
  418. <?php
  419. }
  420. $x++; ?>
  421. <td>
  422. <input type="checkbox"
  423. name="categories[<?= ($CatKey+1) ?>]"
  424. id="cat_<?= ($CatKey+1) ?>" value="1" <?php if (isset($_GET['categories'][$CatKey + 1])) { ?>
  425. checked="checked"<?php } ?> />
  426. <label for="cat_<?= ($CatKey + 1) ?>"><?= $CatName ?></label>
  427. </td>
  428. <?php
  429. }
  430. ?>
  431. </tr>
  432. </table>
  433. <!-- Submit -->
  434. <div class="submit">
  435. <span class="float_left"><?= number_format($TorrentCount) ?>
  436. Results</span>
  437. <input type="submit" value="Search" />
  438. </div>
  439. </form>
  440. </div>
  441. <!-- Results table -->
  442. <?php if (count($GroupIDs) === 0) { ?>
  443. <div class="center">
  444. Nothing found!
  445. </div>
  446. <?php } else { ?>
  447. <div class="linkbox"><?=$Pages?>
  448. </div>
  449. <div class="box">
  450. <table class="torrent_table cats" width="100%">
  451. <tr class="colhead">
  452. <td class="cats_col"></td>
  453. <td><a
  454. href="<?= header_link('Name', 'ASC') ?>">Torrent</a>
  455. </td>
  456. <td><a
  457. href="<?= header_link('Time') ?>">Time</a>
  458. </td>
  459. <td><a
  460. href="<?= header_link('Size') ?>">Size</a>
  461. </td>
  462. <td class="sign snatches">
  463. <a
  464. href="<?= header_link('Snatched') ?>">
  465. <svg width="15" height="15" fill="black" class="tooltip" alt="Snatches" title="Snatches"
  466. viewBox="3 0 88 98">
  467. <path d="M20 20 A43 43,0,1,0,77 23 L90 10 L55 10 L55 45 L68 32 A30.27 30.27,0,1,1,28 29"></path>
  468. </svg>
  469. </a>
  470. </td>
  471. <td class="sign seeders">
  472. <a
  473. href="<?= header_link('Seeders') ?>">
  474. <svg width="11" height="15" fill="black" class="tooltip" alt="Seeders" title="Seeders">
  475. <polygon points="0,7 5.5,0 11,7 8,7 8,15 3,15 3,7"></polygon>
  476. </svg>
  477. </a>
  478. </td>
  479. <td class="sign leechers">
  480. <a
  481. href="<?= header_link('Leechers') ?>">
  482. <svg width="11" height="15" fill="black" class="tooltip" alt="Leechers" title="Leechers">
  483. <polygon points="0,8 5.5,15 11,8 8,8 8,0 3,0 3,8"></polygon>
  484. </svg>
  485. </a>
  486. </td>
  487. </tr>
  488. <!-- Results list -->
  489. <?php
  490. $PageSize = 0;
  491. foreach ($TorrentsInfo as $TorrentID => $Info) {
  492. list($GroupID, , $Time) = array_values($Info);
  493. extract(Torrents::array_group($Results[$GroupID]));
  494. $Torrent = $Torrents[$TorrentID];
  495. $TorrentTags = new Tags($TagList);
  496. $DisplayName = Artists::display_artists($Artists);
  497. $DisplayName .= '<a href="torrents.php?id='.$GroupID.'&amp;torrentid='.$TorrentID.'" ';
  498. if (!isset($LoggedUser['CoverArt']) || $LoggedUser['CoverArt']) {
  499. $DisplayName .= 'data-cover="'.ImageTools::process($WikiImage, 'thumb').'" ';
  500. }
  501. $GroupName = empty($GroupName) ? (empty($GroupNameRJ) ? $GroupNameJP : $GroupNameRJ) : $GroupName;
  502. $DisplayName .= 'dir="ltr">'.$GroupName.'</a>';
  503. if ($GroupYear) {
  504. $DisplayName .= " [$GroupYear]";
  505. }
  506. if ($GroupStudio) {
  507. $DisplayName .= " [$GroupStudio]";
  508. }
  509. if ($GroupCatalogueNumber) {
  510. $DisplayName .= " [$GroupCatalogueNumber]";
  511. }
  512. if ($GroupDLSiteID) {
  513. $DisplayName .= " [$GroupDLSiteID]";
  514. }
  515. $ExtraInfo = Torrents::torrent_info($Torrent);
  516. if ($ExtraInfo) {
  517. $DisplayName .= " - $ExtraInfo";
  518. } ?>
  519. <tr
  520. class="torrent torrent_row<?= ($Torrent['IsSnatched'] ? ' snatched_torrent' : '') . ($GroupFlags['IsSnatched'] ? ' snatched_group' : '') ?>">
  521. <td class="center cats_col">
  522. <div
  523. title="<?= Format::pretty_category($GroupCategoryID) ?>"
  524. class="tooltip <?= Format::css_category($GroupCategoryID) ?>">
  525. </div>
  526. </td>
  527. <td class="big_info">
  528. <div class="group_info clear">
  529. <span class="torrent_links_block">
  530. [ <a
  531. href="torrents.php?action=download&amp;id=<?= $TorrentID ?>&amp;authkey=<?= $LoggedUser['AuthKey'] ?>&amp;torrent_pass=<?= $LoggedUser['torrent_pass'] ?>"
  532. class="tooltip" title="Download">DL</a>
  533. | <a
  534. href="reportsv2.php?action=report&amp;id=<?= $TorrentID ?>"
  535. class="tooltip" title="Report">RP</a> ]
  536. </span>
  537. <?php echo "$DisplayName\n"; ?>
  538. <div class="tags"><?= $TorrentTags->format('torrents.php?type='.$Action.'&amp;userid='.$UserID.'&amp;tags=') ?>
  539. </div>
  540. </div>
  541. </td>
  542. <td class="nobr"><?= time_diff($Time, 1) ?>
  543. </td>
  544. <td class="number_column nobr"><?= Format::get_size($Torrent['Size']) ?>
  545. </td>
  546. <td class="number_column"><?= number_format($Torrent['Snatched']) ?>
  547. </td>
  548. <td
  549. class="number_column<?= (($Torrent['Seeders'] === 0) ? ' r00' : '') ?>">
  550. <?= number_format($Torrent['Seeders']) ?>
  551. </td>
  552. <td class="number_column"><?= number_format($Torrent['Leechers']) ?>
  553. </td>
  554. </tr>
  555. <?php
  556. } ?>
  557. </table>
  558. </div>
  559. <?php } ?>
  560. <div class="linkbox"><?= $Pages ?>
  561. </div>
  562. </div>
  563. <?php View::show_footer();