Empty commit

This commit is contained in:
Git 2011-08-25 08:00:11 +00:00
parent 72a0c00339
commit a89ba892c0
3 changed files with 33 additions and 1 deletions

View File

@ -11,6 +11,7 @@
enforce_login();
switch ($_GET['action']){
// things that (may be) used on the site
case 'upload_section':
// Gets one of the upload forms
require(SERVER_ROOT.'/sections/ajax/upload.php');
@ -31,6 +32,10 @@
require(SERVER_ROOT.'/sections/ajax/stats.php');
break;
// things not yet used on the site
case 'torrentgroup':
require('torrentgroup.php');
break;
default:
// If they're screwing around with the query string
error(403);

View File

@ -0,0 +1,27 @@
<?php
authorize();
require(SERVER_ROOT.'/sections/torrents/functions.php');
$GroupAllowed = array('WikiBody', 'WikiImage', 'ID', 'Name', 'Year', 'RecordLabel', 'CatalogueNumber', 'ReleaseType', 'CategoryID', 'Time', 'VanityHouse');
$TorrentAllowed = array('ID', 'Media', 'Format', 'Encoding', 'Remastered', 'RemasterYear', 'RemasterTitle', 'RemasterRecordLabel', 'RemasterCatalogueNumber', 'Scene', 'HasLog', 'HasCue', 'LogScore', 'FileCount', 'Size', 'Seeders', 'Leechers', 'Snatched', 'FreeTorrent', 'Time', 'Description', 'FileList', 'FilePath', 'UserID', 'Username');
$GroupID = (int)$_GET['id'];
if ($GroupID == 0) { error('bad id parameter', true); }
$TorrentCache = get_group_info($GroupID, true, 0);
// http://stackoverflow.com/questions/4260086/php-how-to-use-array-filter-to-filter-array-keys
function filter_by_key($input, $keys) { return array_intersect_key($input, array_flip($keys)); }
$TorrentDetails = filter_by_key($TorrentCache[0][0], $GroupAllowed);
$TorrentList = array();
foreach ($TorrentCache[1] as $Torrent) {
$TorrentList[] = filter_by_key($Torrent, $TorrentAllowed);
}
header('Content-Type: text/plain; charset=utf-8');
print json_encode(array('status' => 'success', 'response' => array('group' => $TorrentDetails, 'torrents' => $TorrentList)));

View File

@ -594,7 +594,7 @@
<div class="box pad" style="padding:10px 10px 10px 20px;">
<ul>
<li id="r4.4.1"><a href="#h4.4"><strong>&uarr;_</strong></a> <a href="#r4.4.1">4.4.1.</a> <strong>All comic page scans must be zero-padded numbered and may be archived properly in .pdf, .rar (.cbr) or .zip (.cbz).</strong> The contents of the archive or directory must be image files (either JPEG or PNG) named sequentially for display in the correct order by <a href="http://www.zcultfm.com/~comic/wiki/index.php/Comic_Viewers">comic reading software</a> such as <a href="http://www.geocities.com/davidayton/CDisplay.html">CDisplay</a> and <a href="http://www.feedface.com/software/ffview.html">FFView</a>. The page numbers and books must be zero-padded for this same reason. <em>For example, Good numbering: file01.jpg, file02.jpg .. file30.jpg and Bad numbering: file1.jpg, file2.jpg, file3.jpg...file30.jpg.</em>
<li id="r4.4.1"><a href="#h4.4"><strong>&uarr;_</strong></a> <a href="#r4.4.1">4.4.1.</a> <strong>All comic page scans must be zero-padded numbered and may be archived properly in .pdf, .rar (.cbr) or .zip (.cbz).</strong> The contents of the archive or directory must be image files (either JPEG or PNG) named sequentially for display in the correct order by <a href="http://en.wikipedia.org/wiki/Comparison_of_image_viewers">comic reading software</a> such as <a href="http://www.cdisplay.me/">CDisplay</a> and <a href="http://www.feedface.com/software/ffview.html">FFView</a>. The page numbers and books must be zero-padded for this same reason. <em>For example, Good numbering: file01.jpg, file02.jpg .. file30.jpg and Bad numbering: file1.jpg, file2.jpg, file3.jpg...file30.jpg.</em>
</li>
<li id="r4.4.2"><a href="#h4.4"><strong>&uarr;_</strong></a> <a href="#r4.4.2">4.4.2.</a> <strong>Comic book archive file names must be informative.</strong> The archive names should include at least the Book's name (i.e. Uncanny X-Men), the volume (if there's more than one volume of that book) and the issue number. It is recommended to also include the cover year and the scanner information (to differentiate between different scans of the same book), as well as the issue's title (i.e. Days of Future Past). For example: <em>Buffy the Vampire Slayer Season Eight - #01 - 2007 - The Long Way Home Part 1.cbr</em> and <em>Amazing Spiderman - Volume 1 - #10 - 1964.cbz</em>