Browse Source

This is a good place to stop

pjc 5 years ago
parent
commit
ca22a65cbc

+ 18
- 17
classes/artists.class.php View File

95
         if (!empty($Artists)) {
95
         if (!empty($Artists)) {
96
             $ampersand = ($Escape) ? ' & ' : ' & ';
96
             $ampersand = ($Escape) ? ' & ' : ' & ';
97
             $link = '';
97
             $link = '';
98
-
98
+    
99
             switch (count($Artists)) {
99
             switch (count($Artists)) {
100
-        case 0:
101
-          break;
102
-        case 3:
103
-          $link .= Artists::display_artist($Artists[2], $MakeLink, $Escape). ", ";
104
-        break;
105
-        case 2:
106
-          $link .= Artists::display_artist($Artists[1], $MakeLink, $Escape). ", ";
107
-        break;
108
-        case 1:
109
-          $link .= Artists::display_artist($Artists[0], $MakeLink, $Escape).($IncludeHyphen?' – ':'');
110
-          break;
111
-        default:
112
-        $link = Artists::display_artist($Artists[0], $MakeLink, $Escape).' et al.'.($IncludeHyphen?' – ':'');
113
-      }
114
-
100
+            case 0:
101
+              break;
102
+            case 3:
103
+              $link .= Artists::display_artist($Artists[2], $MakeLink, $Escape). ", ";
104
+              // no break
105
+            case 2:
106
+              $link .= Artists::display_artist($Artists[1], $MakeLink, $Escape). ", ";
107
+              // no break
108
+            case 1:
109
+              $link .= Artists::display_artist($Artists[0], $MakeLink, $Escape).($IncludeHyphen? ' – ':'');
110
+              break;
111
+            default:
112
+            $link = Artists::display_artist($Artists[0], $MakeLink, $Escape).'  et al.'.($IncludeHyphen? ' – ':'');
113
+            #$link = "Various".($IncludeHyphen?' – ':'');
114
+        }
115
+    
115
             return $link;
116
             return $link;
116
         } else {
117
         } else {
117
             return '';
118
             return '';
118
         }
119
         }
119
     }
120
     }
120
-
121
+    
121
     /**
122
     /**
122
      * Formats a single artist name.
123
      * Formats a single artist name.
123
      *
124
      *

+ 77
- 60
classes/torrent_form.class.php View File

13
     public $MediaManga = [];
13
     public $MediaManga = [];
14
     public $Containers = [];
14
     public $Containers = [];
15
     public $ContainersGames = [];
15
     public $ContainersGames = [];
16
+    public $ContainersProt = [];
16
     public $Codecs = [];
17
     public $Codecs = [];
17
     public $Resolutions = [];
18
     public $Resolutions = [];
18
     #var $AudioFormats = [];
19
     #var $AudioFormats = [];
32
         $this->Torrent = $Torrent;
33
         $this->Torrent = $Torrent;
33
         $this->Error = $Error;
34
         $this->Error = $Error;
34
 
35
 
35
-        global $UploadForm, $Categories, $Media,  $MediaManga, $TorrentID, $Containers, $ContainersGames, $Codecs, $Resolutions, $Archives;
36
+        global $UploadForm, $Categories, $Media,  $MediaManga, $TorrentID, $Containers, $ContainersGames, $ContainersProt, $Codecs, $Resolutions, $Archives;
36
         #global $UploadForm, $Categories, $Formats, $Bitrates, $Media, $MediaManga, $TorrentID, $Containers, $ContainersGames, $Codecs, $Resolutions, $AudioFormats, $Subbing, $Languages, $Platform, $Archives, $ArchivesManga;
37
         #global $UploadForm, $Categories, $Formats, $Bitrates, $Media, $MediaManga, $TorrentID, $Containers, $ContainersGames, $Codecs, $Resolutions, $AudioFormats, $Subbing, $Languages, $Platform, $Archives, $ArchivesManga;
37
 
38
 
38
         $this->UploadForm = $UploadForm;
39
         $this->UploadForm = $UploadForm;
43
         $this->MediaManga = $MediaManga;
44
         $this->MediaManga = $MediaManga;
44
         $this->Containers = $Containers;
45
         $this->Containers = $Containers;
45
         $this->ContainersGames = $ContainersGames;
46
         $this->ContainersGames = $ContainersGames;
47
+        $this->ContainersProt = $ContainersProt;
46
         $this->Codecs = $Codecs;
48
         $this->Codecs = $Codecs;
47
         $this->Resolutions = $Resolutions;
49
         $this->Resolutions = $Resolutions;
48
         #$this->AudioFormats = $AudioFormats;
50
         #$this->AudioFormats = $AudioFormats;
153
     <table cellpadding="3" cellspacing="1" border="0" class="layout" width="100%">
155
     <table cellpadding="3" cellspacing="1" border="0" class="layout" width="100%">
154
 
156
 
155
       <tr>
157
       <tr>
156
-        <td class="label">
157
-          Torrent File
158
-          <strong class="important_text">*</strong>
159
-        </td>
158
+        <td class="label">Torrent File</td>
160
         <td><input id="file" type="file" name="file_input" size="50" /><br />
159
         <td><input id="file" type="file" name="file_input" size="50" /><br />
161
           Use the above announce URL and set the private flag in your BitTorrent client, e.g.,
160
           Use the above announce URL and set the private flag in your BitTorrent client, e.g.,
162
           <code>mktorrent -p -a &lt;announce&gt; &lt;target folder&gt;</code>
161
           <code>mktorrent -p -a &lt;announce&gt; &lt;target folder&gt;</code>
164
       </tr>
163
       </tr>
165
 
164
 
166
       <tr>
165
       <tr>
167
-        <td class="label">
168
-          Type
169
-          <strong class="important_text">*</strong>
170
-        </td>
166
+        <td class="label">Type</td>
171
         <td>
167
         <td>
172
           <select id="categories" name="type" onchange="Categories()" <?= ($this->DisabledFlag) ? ' disabled="disabled"' : '' ?>>
168
           <select id="categories" name="type" onchange="Categories()" <?= ($this->DisabledFlag) ? ' disabled="disabled"' : '' ?>>
173
             <?php
169
             <?php
419
       Original publication year
415
       Original publication year
420
     </td>
416
     </td>
421
   </tr>
417
   </tr>
418
+  <?php } # Ends if NewTorrent line 256?>
419
+
420
+    <!-- Encoding -->
421
+    <tr id="codec_tr">
422
+    <td class="label">
423
+      License
424
+      <strong class="important_text">*</strong>
425
+    </td>
426
+    <td>
427
+      <select name="codec">
428
+        <option>---</option>
429
+        <?php
430
+          foreach ($this->Codecs as $Codec) {
431
+              echo "\t\t\t\t\t\t<option value=\"$Codec\"";
432
+              if ($Codec === ($Torrent['Codec'] ?? false)) {
433
+                  echo " selected";
434
+              }
435
+              echo ">$Codec</option>\n";
436
+          } ?>
437
+      </select><br />
438
+      Please see <a href="http://www.dcc.ac.uk/resources/how-guides/license-research-data" target="_blank">How to
439
+        License Research Data</a>
440
+    </td>
441
+  </tr>
422
 
442
 
423
   <!-- Media type -->
443
   <!-- Media type -->
424
-  <?php } # Ends if NewTorrent line 256?>
425
   <tr id="media_tr">
444
   <tr id="media_tr">
426
     <td class="label">
445
     <td class="label">
427
       Platform
446
       Platform
429
     </td>
448
     </td>
430
     <td>
449
     <td>
431
       <select name="media">
450
       <select name="media">
432
-        <option>---</option>
433
         <?php
451
         <?php
434
           foreach ($this->Media as $Media) {
452
           foreach ($this->Media as $Media) {
435
               echo "\t\t\t\t\t\t<option value=\"$Media\"";
453
               echo "\t\t\t\t\t\t<option value=\"$Media\"";
465
     </td>
483
     </td>
466
   </tr>
484
   </tr>
467
 
485
 
486
+    <!-- Resolution -->
487
+    <tr id="resolution_tr">
488
+    <td class="label">
489
+      Assembly Level
490
+      <strong class="important_text">*</strong>
491
+    </td>
492
+    <td>
493
+      <select id="ressel" name="ressel" onchange="SetResolution()">
494
+        <option value="">---</option>
495
+        <?php
496
+          foreach ($this->Resolutions as $Res) {
497
+              echo "\t\t\t\t\t\t<option value=\"$Res\"";
498
+              if ($Res === ($Torrent['Resolution'] ?? false)
499
+              || (!isset($FoundRes) && ($Torrent['Resolution'] ?? false)
500
+              && $Res === 'Other')) {
501
+                  echo " selected";
502
+                  $FoundRes = true;
503
+              }
504
+              echo ">$Res</option>\n";
505
+          } ?>
506
+      </select>
507
+
508
+      <input type="text" id="resolution" name="resolution" size="10" class="hidden"
509
+        value="<?= ($Torrent['Resolution']??'') ?>"
510
+        readonly>
511
+      </input>
512
+      <script>
513
+        if ($('#ressel').raw().value == "Other") {
514
+          $('#resolution').raw().readOnly = false
515
+          $('#resolution').gshow()
516
+        }
517
+      </script><br />
518
+      How complete the data is
519
+    </td>
520
+  </tr>
521
+
468
   <!-- Container -->
522
   <!-- Container -->
469
   <tr id="container_tr">
523
   <tr id="container_tr">
470
     <td class="label">
524
     <td class="label">
487
     </td>
541
     </td>
488
   </tr>
542
   </tr>
489
 
543
 
490
-  <!-- Alternate container -->
544
+  <!-- Alternate container 1 -->
491
   <tr id="container_games_tr">
545
   <tr id="container_games_tr">
492
     <td class="label">
546
     <td class="label">
493
       Format
547
       Format
509
     </td>
563
     </td>
510
   </tr>
564
   </tr>
511
 
565
 
512
-  <!-- Resolution -->
513
-  <tr id="resolution_tr">
566
+    <!-- Alternate container 2 -->
567
+    <tr id="container_prot_tr">
514
     <td class="label">
568
     <td class="label">
515
-      Assembly Level
569
+      Format
516
       <strong class="important_text">*</strong>
570
       <strong class="important_text">*</strong>
517
     </td>
571
     </td>
518
     <td>
572
     <td>
519
-      <select id="ressel" name="ressel" onchange="SetResolution()">
520
-        <option value="">---</option>
573
+      <select id="container" name="container">
574
+        <option value="Autofill">Autofill</option>
521
         <?php
575
         <?php
522
-          foreach ($this->Resolutions as $Res) {
523
-              echo "\t\t\t\t\t\t<option value=\"$Res\"";
524
-              if ($Res === ($Torrent['Resolution'] ?? false)
525
-              || (!isset($FoundRes) && ($Torrent['Resolution'] ?? false)
526
-              && $Res === 'Other')) {
576
+          foreach ($this->ContainersProt as $Container) {
577
+              echo "\t\t\t\t\t\t<option value=\"$Container\"";
578
+              if ($Container === ($Torrent['Container'] ?? false)) {
527
                   echo " selected";
579
                   echo " selected";
528
-                  $FoundRes = true;
529
               }
580
               }
530
-              echo ">$Res</option>\n";
581
+              echo ">$Container</option>\n";
531
           } ?>
582
           } ?>
532
-      </select>
533
-
534
-      <input type="text" id="resolution" name="resolution" size="10" class="hidden"
535
-        value="<?= ($Torrent['Resolution']??'') ?>"
536
-        readonly>
537
-      </input>
538
-      <script>
539
-        if ($('#ressel').raw().value == "Other") {
540
-          $('#resolution').raw().readOnly = false
541
-          $('#resolution').gshow()
542
-        }
543
-      </script><br />
544
-      How complete the data is
583
+      </select><br />
584
+      Data file format, or detect from file list
545
     </td>
585
     </td>
546
   </tr>
586
   </tr>
547
 
587
 
567
     </td>
607
     </td>
568
   </tr>
608
   </tr>
569
 
609
 
570
-  <!-- Encoding -->
571
-  <tr id="codec_tr">
572
-    <td class="label">
573
-      License
574
-      <strong class="important_text">*</strong>
575
-    </td>
576
-    <td>
577
-      <select name="codec">
578
-        <option>---</option>
579
-        <?php
580
-          foreach ($this->Codecs as $Codec) {
581
-              echo "\t\t\t\t\t\t<option value=\"$Codec\"";
582
-              if ($Codec === ($Torrent['Codec'] ?? false)) {
583
-                  echo " selected";
584
-              }
585
-              echo ">$Codec</option>\n";
586
-          } ?>
587
-      </select><br />
588
-      Please see <a href="http://www.dcc.ac.uk/resources/how-guides/license-research-data" target="_blank">How to
589
-        License Research Data</a>
590
-    </td>
591
-  </tr>
592
-
593
   <!-- Tags -->
610
   <!-- Tags -->
594
   <?php if ($this->NewTorrent) { ?>
611
   <?php if ($this->NewTorrent) { ?>
595
   <tr id="tags_tr">
612
   <tr id="tags_tr">

+ 1
- 0
classes/validate.class.php View File

44
         foreach ($this->Fields as $FieldKey => $Field) {
44
         foreach ($this->Fields as $FieldKey => $Field) {
45
             $ValidateVar = $ValidateArray[$FieldKey];
45
             $ValidateVar = $ValidateArray[$FieldKey];
46
 
46
 
47
+            # @todo Change this to a switch statement
47
             if ($ValidateVar !== '' || !empty($Field['Required']) || $Field['Type'] === 'date') {
48
             if ($ValidateVar !== '' || !empty($Field['Required']) || $Field['Type'] === 'date') {
48
                 if ($Field['Type'] === 'string') {
49
                 if ($Field['Type'] === 'string') {
49
                     if (isset($Field['MaxLength'])) {
50
                     if (isset($Field['MaxLength'])) {

+ 49
- 38
gazelle.sql View File

1
+-- Please see the limits for kinds of fields below.
2
+--
3
+--   * Gazelle ID numbers: int(10)
4
+--   * Accession numbers:  varchar(50)
5
+--   * Gazelle titles:     varchar(50)
6
+--   * Torrent titles:     varchar(255)
7
+--   * Ocelot tokens:      char(32)
8
+--   * Tag lists:          varchar(500)
9
+--
10
+-- @todo Finish explaining the schema
11
+
1
 SET FOREIGN_KEY_CHECKS = 0;
12
 SET FOREIGN_KEY_CHECKS = 0;
2
 
13
 
3
 CREATE DATABASE gazelle_production CHARACTER SET utf8mb4;
14
 CREATE DATABASE gazelle_production CHARACTER SET utf8mb4;
7
 CREATE TABLE `api_applications` (
18
 CREATE TABLE `api_applications` (
8
   `ID` int(10) NOT NULL AUTO_INCREMENT,
19
   `ID` int(10) NOT NULL AUTO_INCREMENT,
9
   `UserID` int(10) NOT NULL,
20
   `UserID` int(10) NOT NULL,
10
-  `Token` char(32) NOT NULL,
21
+  `Token` char(32) NOT NULL, -- Ocelot 32-character limit
11
   `Name` varchar(50) NOT NULL,
22
   `Name` varchar(50) NOT NULL,
12
   PRIMARY KEY (`ID`)
23
   PRIMARY KEY (`ID`)
13
 ) ENGINE=InnoDB CHARSET=utf8mb4;
24
 ) ENGINE=InnoDB CHARSET=utf8mb4;
15
 CREATE TABLE `api_users` (
26
 CREATE TABLE `api_users` (
16
   `UserID` int(10) NOT NULL,
27
   `UserID` int(10) NOT NULL,
17
   `AppID` int(10) NOT NULL,
28
   `AppID` int(10) NOT NULL,
18
-  `Token` char(32) NOT NULL,
29
+  `Token` char(32) NOT NULL, -- Ocelot 32-character limit
19
   `State` enum('0','1','2') NOT NULL DEFAULT '0',
30
   `State` enum('0','1','2') NOT NULL DEFAULT '0',
20
   `Time` datetime,
31
   `Time` datetime,
21
   `Access` text,
32
   `Access` text,
677
   `ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
688
   `ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
678
   `ReporterID` int(10) unsigned NOT NULL DEFAULT '0',
689
   `ReporterID` int(10) unsigned NOT NULL DEFAULT '0',
679
   `TorrentID` int(10) unsigned NOT NULL DEFAULT '0',
690
   `TorrentID` int(10) unsigned NOT NULL DEFAULT '0',
680
-  `Type` varchar(20) DEFAULT '',
691
+  `Type` varchar(25) DEFAULT '',
681
   `UserComment` text,
692
   `UserComment` text,
682
   `ResolverID` int(10) unsigned NOT NULL DEFAULT '0',
693
   `ResolverID` int(10) unsigned NOT NULL DEFAULT '0',
683
   `Status` enum('New','InProgress','Resolved') DEFAULT 'New',
694
   `Status` enum('New','InProgress','Resolved') DEFAULT 'New',
822
   `Resolution` varchar(255) DEFAULT NULL,
833
   `Resolution` varchar(255) DEFAULT NULL,
823
   `AudioFormat` varchar(255) DEFAULT NULL,
834
   `AudioFormat` varchar(255) DEFAULT NULL,
824
   `Subbing` varchar(255) DEFAULT NULL,
835
   `Subbing` varchar(255) DEFAULT NULL,
825
-  `Studio` varchar(80) DEFAULT NULL,
826
-  `Series` varchar(80) DEFAULT NULL,
827
-  `DLsiteID` varchar(20) DEFAULT NULL,
836
+  `Studio` varchar(100) DEFAULT NULL,
837
+  `Series` varchar(100) DEFAULT NULL,
838
+  `DLsiteID` varchar(25) DEFAULT NULL,
828
   `Language` varchar(255) DEFAULT NULL,
839
   `Language` varchar(255) DEFAULT NULL,
829
   `Censored` tinyint(1) NOT NULL DEFAULT '1',
840
   `Censored` tinyint(1) NOT NULL DEFAULT '1',
830
   `FileList` mediumtext,
841
   `FileList` mediumtext,
834
   PRIMARY KEY (`ID`),
845
   PRIMARY KEY (`ID`),
835
   KEY `GroupID` (`GroupID`),
846
   KEY `GroupID` (`GroupID`),
836
   KEY `Size` (`Size`)
847
   KEY `Size` (`Size`)
837
-) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4;
848
+) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
838
 
849
 
839
 CREATE TABLE `sphinx_index_last_pos` (
850
 CREATE TABLE `sphinx_index_last_pos` (
840
   `Type` varchar(16) NOT NULL DEFAULT '',
851
   `Type` varchar(16) NOT NULL DEFAULT '',
911
   `leechers` int(11) NOT NULL,
922
   `leechers` int(11) NOT NULL,
912
   `time` int(11) NOT NULL,
923
   `time` int(11) NOT NULL,
913
   `freetorrent` tinyint(4) NOT NULL,
924
   `freetorrent` tinyint(4) NOT NULL,
914
-  `media` varchar(15) NOT NULL,
915
-  `container` varchar(15) NOT NULL,
916
-  `resolution` varchar(15) NOT NULL,
917
-  `codec` varchar(15) NOT NULL,
918
-  `audioformat` varchar(15) NOT NULL,
919
-  `subbing` varchar(15) NOT NULL,
920
-  `language` varchar(15) NOT NULL,
925
+  `media` varchar(25) NOT NULL,
926
+  `container` varchar(25) NOT NULL,
927
+  `resolution` varchar(25) NOT NULL,
928
+  `codec` varchar(25) NOT NULL,
929
+  `audioformat` varchar(25) NOT NULL,
930
+  `subbing` varchar(25) NOT NULL,
931
+  `language` varchar(25) NOT NULL,
921
   `filelist` mediumtext,
932
   `filelist` mediumtext,
922
   `description` text,
933
   `description` text,
923
   `subber` varchar(30) NOT NULL,
934
   `subber` varchar(30) NOT NULL,
928
 
939
 
929
 CREATE TABLE `sphinx_tg` (
940
 CREATE TABLE `sphinx_tg` (
930
   `id` int(11) NOT NULL,
941
   `id` int(11) NOT NULL,
931
-  `name` varchar(300) DEFAULT NULL,
932
-  `namerj` varchar(300) DEFAULT NULL,
933
-  `namejp` varchar(500) DEFAULT NULL,
942
+  `name` varchar(255) DEFAULT NULL,
943
+  `namerj` varchar(255) DEFAULT NULL,
944
+  `namejp` varchar(255) DEFAULT NULL,
934
   `tags` varchar(500) DEFAULT NULL,
945
   `tags` varchar(500) DEFAULT NULL,
935
   `year` smallint(6) DEFAULT NULL,
946
   `year` smallint(6) DEFAULT NULL,
936
-  `cnumber` varchar(80) DEFAULT NULL,
937
-  `studio` varchar(300) DEFAULT NULL,
938
-  `series` varchar(300) DEFAULT NULL,
947
+  `cnumber` varchar(50) DEFAULT NULL,
948
+  `studio` varchar(255) DEFAULT NULL,
949
+  `series` varchar(255) DEFAULT NULL,
939
   `catid` smallint(6) DEFAULT NULL,
950
   `catid` smallint(6) DEFAULT NULL,
940
   `dlsid` varchar(15) NOT NULL,
951
   `dlsid` varchar(15) NOT NULL,
941
   PRIMARY KEY (`id`)
952
   PRIMARY KEY (`id`)
1069
   `ID` int(10) NOT NULL AUTO_INCREMENT,
1080
   `ID` int(10) NOT NULL AUTO_INCREMENT,
1070
   `GroupID` int(10) NOT NULL DEFAULT '0',
1081
   `GroupID` int(10) NOT NULL DEFAULT '0',
1071
   `UserID` int(10) DEFAULT NULL,
1082
   `UserID` int(10) DEFAULT NULL,
1072
-  `Media` varchar(20) DEFAULT NULL,
1073
-  `Container` varchar(20) DEFAULT NULL,
1074
-  `Codec` varchar(20) DEFAULT NULL,
1075
-  `Resolution` varchar(20) DEFAULT NULL,
1083
+  `Media` varchar(25) DEFAULT NULL,
1084
+  `Container` varchar(25) DEFAULT NULL,
1085
+  `Codec` varchar(25) DEFAULT NULL,
1086
+  `Resolution` varchar(25) DEFAULT NULL,
1076
   `AudioFormat` varchar(10) DEFAULT NULL,
1087
   `AudioFormat` varchar(10) DEFAULT NULL,
1077
   `Subbing` varchar(10) DEFAULT NULL,
1088
   `Subbing` varchar(10) DEFAULT NULL,
1078
-  `Language` varchar(20) DEFAULT NULL,
1089
+  `Language` varchar(25) DEFAULT NULL,
1079
   `Censored` tinyint(1) NOT NULL DEFAULT '1',
1090
   `Censored` tinyint(1) NOT NULL DEFAULT '1',
1080
   `Anonymous` tinyint(1) NOT NULL DEFAULT '0',
1091
   `Anonymous` tinyint(1) NOT NULL DEFAULT '0',
1081
   `info_hash` blob NOT NULL,
1092
   `info_hash` blob NOT NULL,
1094
   `Snatched` int(10) unsigned NOT NULL DEFAULT '0',
1105
   `Snatched` int(10) unsigned NOT NULL DEFAULT '0',
1095
   `balance` bigint(20) NOT NULL DEFAULT '0',
1106
   `balance` bigint(20) NOT NULL DEFAULT '0',
1096
   `LastReseedRequest` datetime,
1107
   `LastReseedRequest` datetime,
1097
-  `Subber` varchar(300) NOT NULL DEFAULT '',
1108
+  `Subber` varchar(255) NOT NULL DEFAULT '',
1098
   `Archive` varchar(10) NOT NULL DEFAULT '',
1109
   `Archive` varchar(10) NOT NULL DEFAULT '',
1099
   PRIMARY KEY (`ID`),
1110
   PRIMARY KEY (`ID`),
1100
   UNIQUE KEY `InfoHash` (`info_hash`(40)),
1111
   UNIQUE KEY `InfoHash` (`info_hash`(40)),
1153
   `NameRJ` varchar(255) DEFAULT NULL,
1164
   `NameRJ` varchar(255) DEFAULT NULL,
1154
   `NameJP` varchar(255) DEFAULT NULL,
1165
   `NameJP` varchar(255) DEFAULT NULL,
1155
   `Year` int(4) DEFAULT NULL,
1166
   `Year` int(4) DEFAULT NULL,
1156
-  `Studio` varchar(80) NOT NULL DEFAULT '',
1157
-  `Series` varchar(80) NOT NULL DEFAULT '',
1158
-  `CatalogueNumber` varchar(80) NOT NULL DEFAULT '',
1167
+  `Studio` varchar(100) NOT NULL DEFAULT '',
1168
+  `Series` varchar(100) NOT NULL DEFAULT '',
1169
+  `CatalogueNumber` varchar(50) NOT NULL DEFAULT '',
1159
   `Pages` smallint(5) unsigned DEFAULT NULL,
1170
   `Pages` smallint(5) unsigned DEFAULT NULL,
1160
   `TagList` varchar(500) NOT NULL DEFAULT '',
1171
   `TagList` varchar(500) NOT NULL DEFAULT '',
1161
   `Time` datetime,
1172
   `Time` datetime,
1162
   `RevisionID` int(12) DEFAULT NULL,
1173
   `RevisionID` int(12) DEFAULT NULL,
1163
   `WikiBody` text,
1174
   `WikiBody` text,
1164
   `WikiImage` varchar(255) NOT NULL,
1175
   `WikiImage` varchar(255) NOT NULL,
1165
-  `DLsiteID` varchar(20) NOT NULL DEFAULT '',
1176
+  `DLsiteID` varchar(25) NOT NULL DEFAULT '',
1166
   PRIMARY KEY (`ID`),
1177
   PRIMARY KEY (`ID`),
1167
   KEY `CategoryID` (`CategoryID`),
1178
   KEY `CategoryID` (`CategoryID`),
1168
   KEY `Name` (`Name`(255)),
1179
   KEY `Name` (`Name`(255)),
1195
   PRIMARY KEY (`TorrentID`),
1206
   PRIMARY KEY (`TorrentID`),
1196
   KEY `GroupID` (`GroupID`),
1207
   KEY `GroupID` (`GroupID`),
1197
   KEY `Stats` (`TorrentID`,`Seeders`,`Leechers`,`Snatches`)
1208
   KEY `Stats` (`TorrentID`,`Seeders`,`Leechers`,`Snatches`)
1198
-) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4;
1209
+) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
1199
 
1210
 
1200
 CREATE TABLE `torrents_peerlists_compare` (
1211
 CREATE TABLE `torrents_peerlists_compare` (
1201
   `TorrentID` int(11) NOT NULL,
1212
   `TorrentID` int(11) NOT NULL,
1206
   PRIMARY KEY (`TorrentID`),
1217
   PRIMARY KEY (`TorrentID`),
1207
   KEY `GroupID` (`GroupID`),
1218
   KEY `GroupID` (`GroupID`),
1208
   KEY `Stats` (`TorrentID`,`Seeders`,`Leechers`,`Snatches`)
1219
   KEY `Stats` (`TorrentID`,`Seeders`,`Leechers`,`Snatches`)
1209
-) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4;
1220
+) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
1210
 
1221
 
1211
 CREATE TABLE `torrents_recommended` (
1222
 CREATE TABLE `torrents_recommended` (
1212
   `GroupID` int(10) NOT NULL,
1223
   `GroupID` int(10) NOT NULL,
1460
 
1471
 
1461
 CREATE TABLE `users_main` (
1472
 CREATE TABLE `users_main` (
1462
   `ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
1473
   `ID` int(10) unsigned NOT NULL AUTO_INCREMENT,
1463
-  `Username` varchar(20) NOT NULL,
1474
+  `Username` varchar(25) NOT NULL,
1464
   `Email` varchar(255) NOT NULL,
1475
   `Email` varchar(255) NOT NULL,
1465
   `PassHash` varchar(60) NOT NULL,
1476
   `PassHash` varchar(60) NOT NULL,
1466
   `TwoFactor` varchar(255) DEFAULT NULL,
1477
   `TwoFactor` varchar(255) DEFAULT NULL,
1720
 
1731
 
1721
 CREATE TABLE `xbt_client_whitelist` (
1732
 CREATE TABLE `xbt_client_whitelist` (
1722
   `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
1733
   `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
1723
-  `peer_id` varchar(20) DEFAULT NULL,
1724
-  `vstring` varchar(200) DEFAULT '',
1734
+  `peer_id` varchar(25) DEFAULT NULL,
1735
+  `vstring` varchar(255) DEFAULT '',
1725
   PRIMARY KEY (`id`),
1736
   PRIMARY KEY (`id`),
1726
   UNIQUE KEY `peer_id` (`peer_id`)
1737
   UNIQUE KEY `peer_id` (`peer_id`)
1727
 ) ENGINE=InnoDB CHARSET=utf8mb4;
1738
 ) ENGINE=InnoDB CHARSET=utf8mb4;
1743
   `peer_id` binary(20) NOT NULL DEFAULT '\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0',
1754
   `peer_id` binary(20) NOT NULL DEFAULT '\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0',
1744
   `fid` int(11) NOT NULL,
1755
   `fid` int(11) NOT NULL,
1745
   `mtime` int(11) NOT NULL,
1756
   `mtime` int(11) NOT NULL,
1746
-  `ip` varchar(15) NOT NULL DEFAULT '',
1757
+  `ip` varchar(15) NOT NULL DEFAULT '', -- Max IPv4 address length
1747
   `seeder` tinyint(1) NOT NULL DEFAULT '0',
1758
   `seeder` tinyint(1) NOT NULL DEFAULT '0',
1748
   PRIMARY KEY (`peer_id`,`fid`,`uid`),
1759
   PRIMARY KEY (`peer_id`,`fid`,`uid`),
1749
   KEY `remaining_idx` (`remaining`),
1760
   KEY `remaining_idx` (`remaining`),
1756
   `uid` int(11) NOT NULL DEFAULT '0',
1767
   `uid` int(11) NOT NULL DEFAULT '0',
1757
   `tstamp` int(11) NOT NULL,
1768
   `tstamp` int(11) NOT NULL,
1758
   `fid` int(11) NOT NULL,
1769
   `fid` int(11) NOT NULL,
1759
-  `IP` varchar(15) NOT NULL,
1770
+  `IP` varchar(15) NOT NULL, -- Max IPv4 address length
1760
   `seedtime` int(11) NOT NULL DEFAULT '0',
1771
   `seedtime` int(11) NOT NULL DEFAULT '0',
1761
   KEY `fid` (`fid`),
1772
   KEY `fid` (`fid`),
1762
   KEY `tstamp` (`tstamp`),
1773
   KEY `tstamp` (`tstamp`),
1777
 
1788
 
1778
 INSERT INTO forums (ID, CategoryID, Sort, Name, Description, MinClassRead, MinClassWrite, MinClassCreate, NumTopics, NumPosts, LastPostID, LastPostAuthorID, LastPostTopicID, LastPostTime) VALUES (1, 1, 20, 'Your Site', 'Totally rad forum', 100, 100, 100, 0, 0, 0, 0, 0, NULL), (2, 5, 30, 'Chat', 'Expect this to fill up with spam', 100, 100, 100, 0, 0, 0, 0, 0, NULL), (3, 10, 40, 'Help!', 'I fell down and I cant get up', 100, 100, 100, 0, 0, 0, 0, 0, NULL), (4, 20, 100, 'Trash', 'Every thread ends up here eventually', 100, 500, 500, 0, 0, 0, 0, 0, NULL);
1789
 INSERT INTO forums (ID, CategoryID, Sort, Name, Description, MinClassRead, MinClassWrite, MinClassCreate, NumTopics, NumPosts, LastPostID, LastPostAuthorID, LastPostTopicID, LastPostTime) VALUES (1, 1, 20, 'Your Site', 'Totally rad forum', 100, 100, 100, 0, 0, 0, 0, 0, NULL), (2, 5, 30, 'Chat', 'Expect this to fill up with spam', 100, 100, 100, 0, 0, 0, 0, 0, NULL), (3, 10, 40, 'Help!', 'I fell down and I cant get up', 100, 100, 100, 0, 0, 0, 0, 0, NULL), (4, 20, 100, 'Trash', 'Every thread ends up here eventually', 100, 500, 500, 0, 0, 0, 0, 0, NULL);
1779
 
1790
 
1780
-INSERT INTO tags (ID, Name, TagType, Uses, UserID) VALUES (1, 'foo', 'genre', 0, 1),(2, 'bar', 'genre', 0, 1),(3, 'baz', 'genre', 0, 1);
1791
+INSERT INTO tags (ID, Name, TagType, Uses, UserID) VALUES (1, 'one', 'genre', 0, 1),(2, 'two', 'genre', 0, 1),(3, 'three', 'genre', 0, 1),(3, 'four', 'genre', 0, 1),(3, 'five', 'genre', 0, 1);
1781
 
1792
 
1782
 INSERT INTO schedule (NextHour, NextDay, NextBiWeekly) VALUES (0,0,0);
1793
 INSERT INTO schedule (NextHour, NextDay, NextBiWeekly) VALUES (0,0,0);
1783
 
1794
 

+ 39
- 39
sections/collages/new_handle.php View File

1
 <?php
1
 <?php
2
-authorize();
3
 
2
 
3
+authorize();
4
 include(SERVER_ROOT.'/classes/validate.class.php');
4
 include(SERVER_ROOT.'/classes/validate.class.php');
5
+
5
 $Val = new Validate;
6
 $Val = new Validate;
6
 
7
 
7
 $P = [];
8
 $P = [];
8
 $P = db_array($_POST);
9
 $P = db_array($_POST);
9
 
10
 
10
 if ($P['category'] > 0 || check_perms('site_collages_renamepersonal')) {
11
 if ($P['category'] > 0 || check_perms('site_collages_renamepersonal')) {
11
-  $Val->SetFields('name', '1', 'string', 'The name must be between 3 and 100 characters', array('maxlength' => 100, 'minlength' => 3));
12
+    $Val->SetFields('name', '1', 'string', 'The name must be between 5 and 255 characters.', array('maxlength' => 255, 'minlength' => 5));
12
 } else {
13
 } else {
13
-  // Get a collage name and make sure it's unique
14
-  $name = $LoggedUser['Username']."'s personal collage";
15
-  $P['name'] = db_string($name);
16
-  $DB->query("
14
+    // Get a collage name and make sure it's unique
15
+    $name = $LoggedUser['Username']."'s personal collage";
16
+    $P['name'] = db_string($name);
17
+    $DB->query("
17
     SELECT ID
18
     SELECT ID
18
     FROM collages
19
     FROM collages
19
     WHERE Name = '".$P['name']."'");
20
     WHERE Name = '".$P['name']."'");
20
-  $i = 2;
21
-  while ($DB->has_results()) {
22
-    $P['name'] = db_string("$name no. $i");
23
-    $DB->query("
21
+    $i = 2;
22
+    while ($DB->has_results()) {
23
+        $P['name'] = db_string("$name no. $i");
24
+        $DB->query("
24
       SELECT ID
25
       SELECT ID
25
       FROM collages
26
       FROM collages
26
       WHERE Name = '".$P['name']."'");
27
       WHERE Name = '".$P['name']."'");
27
-    $i++;
28
-  }
28
+        $i++;
29
+    }
29
 }
30
 }
30
-$Val->SetFields('description', '1', 'string', 'The description must be between 10 and 65535 characters', array('maxlength' => 65535, 'minlength' => 10));
31
+$Val->SetFields('description', '1', 'string', 'The description must be between 10 and 65535 characters.', array('maxlength' => 65535, 'minlength' => 10));
31
 
32
 
32
 $Err = $Val->ValidateForm($_POST);
33
 $Err = $Val->ValidateForm($_POST);
33
 
34
 
34
 if (!$Err && $P['category'] === '0') {
35
 if (!$Err && $P['category'] === '0') {
35
-  $DB->query("
36
+    $DB->query("
36
     SELECT COUNT(ID)
37
     SELECT COUNT(ID)
37
     FROM collages
38
     FROM collages
38
     WHERE UserID = '$LoggedUser[ID]'
39
     WHERE UserID = '$LoggedUser[ID]'
39
       AND CategoryID = '0'
40
       AND CategoryID = '0'
40
       AND Deleted = '0'");
41
       AND Deleted = '0'");
41
-  list($CollageCount) = $DB->next_record();
42
-  if (($CollageCount >= $LoggedUser['Permissions']['MaxCollages']) || !check_perms('site_collages_personal')) {
43
-    $Err = 'You may not create a personal collage.';
44
-  } elseif (check_perms('site_collages_renamepersonal') && !stristr($P['name'], $LoggedUser['Username'])) {
45
-    $Err = 'Your personal collage\'s title must include your username.';
46
-  }
42
+    list($CollageCount) = $DB->next_record();
43
+    if (($CollageCount >= $LoggedUser['Permissions']['MaxCollages']) || !check_perms('site_collages_personal')) {
44
+        $Err = 'You may not create a personal collage.';
45
+    } elseif (check_perms('site_collages_renamepersonal') && !stristr($P['name'], $LoggedUser['Username'])) {
46
+        $Err = "Your personal collage's title must include your username.";
47
+    }
47
 }
48
 }
48
 
49
 
49
 if (!$Err) {
50
 if (!$Err) {
50
-  $DB->query("
51
+    $DB->query("
51
     SELECT ID, Deleted
52
     SELECT ID, Deleted
52
     FROM collages
53
     FROM collages
53
     WHERE Name = '$P[name]'");
54
     WHERE Name = '$P[name]'");
54
-  if ($DB->has_results()) {
55
-    list($ID, $Deleted) = $DB->next_record();
56
-    if ($Deleted) {
57
-      $Err = 'That collection already exists but needs to be recovered; please <a href="staffpm.php">contact</a> the staff team!';
58
-    } else {
59
-      $Err = "That collection already exists: <a href=\"/collages.php?id=$ID\">$ID</a>.";
55
+    if ($DB->has_results()) {
56
+        list($ID, $Deleted) = $DB->next_record();
57
+        if ($Deleted) {
58
+            $Err = 'That collection already exists but needs to be recovered. Please <a href="staffpm.php">contact</a> the staff team.';
59
+        } else {
60
+            $Err = "That collection already exists: <a href='/collages.php?id=$ID'>$ID</a>.";
61
+        }
60
     }
62
     }
61
-  }
62
 }
63
 }
63
 
64
 
64
 if (!$Err) {
65
 if (!$Err) {
65
-  if (empty($CollageCats[$P['category']])) {
66
-    $Err = 'Please select a category';
67
-  }
66
+    if (empty($CollageCats[$P['category']])) {
67
+        $Err = 'Please select a category';
68
+    }
68
 }
69
 }
69
 
70
 
70
 if ($Err) {
71
 if ($Err) {
71
-  $Name = $_POST['name'];
72
-  $Category = $_POST['category'];
73
-  $Tags = $_POST['tags'];
74
-  $Description = $_POST['description'];
75
-  include(SERVER_ROOT.'/sections/collages/new.php');
76
-  die();
72
+    $Name = $_POST['name'];
73
+    $Category = $_POST['category'];
74
+    $Tags = $_POST['tags'];
75
+    $Description = $_POST['description'];
76
+    include(SERVER_ROOT.'/sections/collages/new.php');
77
+    die();
77
 }
78
 }
78
 
79
 
79
 $TagList = explode(',', $_POST['tags']);
80
 $TagList = explode(',', $_POST['tags']);
80
 foreach ($TagList as $ID => $Tag) {
81
 foreach ($TagList as $ID => $Tag) {
81
-  $TagList[$ID] = Misc::sanitize_tag($Tag);
82
+    $TagList[$ID] = Misc::sanitize_tag($Tag);
82
 }
83
 }
83
 $TagList = implode(' ', $TagList);
84
 $TagList = implode(' ', $TagList);
84
 
85
 
92
 $Cache->delete_value("collage_$CollageID");
93
 $Cache->delete_value("collage_$CollageID");
93
 Misc::write_log("Collage $CollageID (".$_POST['name'].') was created by '.$LoggedUser['Username']);
94
 Misc::write_log("Collage $CollageID (".$_POST['name'].') was created by '.$LoggedUser['Username']);
94
 header("Location: collages.php?id=$CollageID");
95
 header("Location: collages.php?id=$CollageID");
95
-?>

+ 47
- 38
sections/requests/new_edit.php View File

100
 <!-- HTML title -->
100
 <!-- HTML title -->
101
 <div class="thin">
101
 <div class="thin">
102
   <div class="header">
102
   <div class="header">
103
-    <h2><?= ($NewRequest ? 'Create Request' : 'Edit Request') ?></h2>
103
+    <h2><?= ($NewRequest ? 'Create Request' : 'Edit Request') ?>
104
+    </h2>
104
   </div>
105
   </div>
105
 
106
 
106
   <!-- New request hidden fields -->
107
   <!-- New request hidden fields -->
120
       <!-- Main table -->
121
       <!-- Main table -->
121
       <table class="layout">
122
       <table class="layout">
122
         <tr>
123
         <tr>
123
-          <td colspan="2" class="center">Please make sure your request follows <a href="rules.php?p=requests">the request rules</a>!</td>
124
+          <td colspan="2" class="center">Please make sure your request follows <a href="rules.php?p=requests">the
125
+              request rules</a>!</td>
124
         </tr>
126
         </tr>
125
         <?php  if ($NewRequest || $CanEdit) { ?>
127
         <?php  if ($NewRequest || $CanEdit) { ?>
126
 
128
 
183
               <?= $Disabled ?>/>
185
               <?= $Disabled ?>/>
184
           </td>
186
           </td>
185
         </tr>
187
         </tr>
186
-        <?php  } # Ends if NewRequest line 123 ?>
188
+        <?php  } # Ends if NewRequest line 123?>
187
 
189
 
188
         <!-- Multiple artists -->
190
         <!-- Multiple artists -->
189
         <tr id="artist_tr">
191
         <tr id="artist_tr">
191
           <td id="artistfields">
193
           <td id="artistfields">
192
             <?php
194
             <?php
193
               if (!empty($ArtistForm)) {
195
               if (!empty($ArtistForm)) {
194
-                $First = true;
195
-                foreach ($ArtistForm as $Artist) {
196
-                  # Cycle autocomplete
197
-            ?>
196
+                  $First = true;
197
+                  foreach ($ArtistForm as $Artist) {
198
+                      # Cycle autocomplete?>
198
             <input type="text" id="artist_0" name="artists[]" <?php Users::has_autocomplete_enabled('other'); ?>
199
             <input type="text" id="artist_0" name="artists[]" <?php Users::has_autocomplete_enabled('other'); ?>
199
             size="45" value="<?= display_str($Artist['name']) ?>" <?= $Disabled ?>/>
200
             size="45" value="<?= display_str($Artist['name']) ?>" <?= $Disabled ?>/>
200
             <?php
201
             <?php
201
               if (empty($Disabled)) {
202
               if (empty($Disabled)) {
202
-                if ($First) { ?>
203
+                  if ($First) { ?>
203
             <a class="add_artist_button brackets">+</a>
204
             <a class="add_artist_button brackets">+</a>
204
             <a class="remove_artist_button brackets">&minus;</a>
205
             <a class="remove_artist_button brackets">&minus;</a>
205
             <?php
206
             <?php
206
                 }
207
                 }
207
-                $First = false;
208
-              }
209
-            ?>
208
+                  $First = false;
209
+              } ?>
210
             <br />
210
             <br />
211
             <?php
211
             <?php
212
-                }
212
+                  }
213
               } else {
213
               } else {
214
-            ?>
214
+                  ?>
215
             <input type="text" id="artist_0" name="artists[]" <?php Users::has_autocomplete_enabled('other'); ?>
215
             <input type="text" id="artist_0" name="artists[]" <?php Users::has_autocomplete_enabled('other'); ?>
216
             size="45" <?= $Disabled ?>/>
216
             size="45" <?= $Disabled ?>/>
217
             <?php if (empty($Disabled)) { ?>
217
             <?php if (empty($Disabled)) { ?>
218
             <a class="add_artist_button brackets">+</a> <a class="remove_artist_button brackets">&minus;</a>
218
             <a class="add_artist_button brackets">+</a> <a class="remove_artist_button brackets">&minus;</a>
219
             <?php
219
             <?php
220
-                } 
220
+                }
221
               }
221
               }
222
             ?>
222
             ?>
223
           </td>
223
           </td>
242
             <?php
242
             <?php
243
               $GenreTags = $Cache->get_value('genre_tags');
243
               $GenreTags = $Cache->get_value('genre_tags');
244
                 if (!$GenreTags) {
244
                 if (!$GenreTags) {
245
-                  $DB->query('
245
+                    $DB->query('
246
                     SELECT Name
246
                     SELECT Name
247
                     FROM tags
247
                     FROM tags
248
                     WHERE TagType = \'genre\'
248
                     WHERE TagType = \'genre\'
249
                     ORDER BY Name');
249
                     ORDER BY Name');
250
-                  $GenreTags = $DB->collect('Name');
251
-                  $Cache->cache_value('genre_tags', $GenreTags, 3600 * 6);
250
+                    $GenreTags = $DB->collect('Name');
251
+                    $Cache->cache_value('genre_tags', $GenreTags, 3600 * 6);
252
                 }
252
                 }
253
 
253
 
254
                 if (!empty($Disabled)) {
254
                 if (!empty($Disabled)) {
255
-            ?>
255
+                    ?>
256
             <select id="genre_tags" name="genre_tags" onchange="add_tag(); return false;" disabled="disabled">
256
             <select id="genre_tags" name="genre_tags" onchange="add_tag(); return false;" disabled="disabled">
257
-            <?php } else { ?>
258
-            <select id="genre_tags" name="genre_tags" onchange="add_tag(); return false;">
259
-              <?php } ?>
260
-              <option>---</option>
261
-              <?php foreach (Misc::display_array($GenreTags) as $Genre) { ?>
262
-              <option value="<?= $Genre ?>"><?= $Genre ?>
263
-              </option>
264
-              <?php  } ?>
265
-            </select>
266
-            <input type="text" id="tags" name="tags" size="45"
267
-              value="<?= (!empty($Tags) ? display_str($Tags) : '') ?>"
268
-              <?php Users::has_autocomplete_enabled('other'); ?>
257
+              <?php
258
+                } else { ?>
259
+              <select id="genre_tags" name="genre_tags" onchange="add_tag(); return false;">
260
+                <?php } ?>
261
+                <option>---</option>
262
+                <?php foreach (Misc::display_array($GenreTags) as $Genre) { ?>
263
+                <option value="<?= $Genre ?>"><?= $Genre ?>
264
+                </option>
265
+                <?php  } ?>
266
+              </select>
267
+              <input type="text" id="tags" name="tags" size="45"
268
+                value="<?= (!empty($Tags) ? display_str($Tags) : '') ?>"
269
+                <?php Users::has_autocomplete_enabled('other'); ?>
269
               <?= $Disabled ?>/>
270
               <?= $Disabled ?>/>
270
           </td>
271
           </td>
271
         </tr>
272
         </tr>
283
         <tr>
284
         <tr>
284
           <td class="label">Torrent Group</td>
285
           <td class="label">Torrent Group</td>
285
           <td>
286
           <td>
286
-            If this request matches a torrent group <strong>already existing</strong> on the site, please indicate that here.<br />
287
+            If this request matches a torrent group <strong>already existing</strong> on the site, please indicate that
288
+            here.<br />
287
             <?= site_url() ?>torrents.php?id=<input type="text"
289
             <?= site_url() ?>torrents.php?id=<input type="text"
288
               name="groupid"
290
               name="groupid"
289
               value="<?= isset($GroupID)?$GroupID:'' ?>"
291
               value="<?= isset($GroupID)?$GroupID:'' ?>"
295
             #&& ($CategoryID !== 5) # ?
297
             #&& ($CategoryID !== 5) # ?
296
             #&& ($CategoryID !== 0) # ?
298
             #&& ($CategoryID !== 0) # ?
297
             ) {
299
             ) {
298
-        ?>
300
+              ?>
299
 
301
 
300
         <!-- Torrent group admin -->
302
         <!-- Torrent group admin -->
301
         <tr>
303
         <tr>
302
           <td class="label">Torrent Group</td>
304
           <td class="label">Torrent Group</td>
303
           <td>
305
           <td>
304
             <a href="torrents.php?id=<?= $GroupID ?>"><?= site_url() ?>torrents.php?id=<?= $GroupID ?></a><br />
306
             <a href="torrents.php?id=<?= $GroupID ?>"><?= site_url() ?>torrents.php?id=<?= $GroupID ?></a><br />
305
-            This request <?= ($NewRequest ? 'will be' : 'is') ?> associated with the above torrent group.
307
+            This request <?= ($NewRequest ? 'will be' : 'is') ?>
308
+            associated with the above torrent group.
306
             <?php if (!$NewRequest) { ?>
309
             <?php if (!$NewRequest) { ?>
307
             If this is incorrect, please
310
             If this is incorrect, please
308
-            <a href="reports.php?action=report&amp;type=request&amp;id=<?= $RequestID ?>">report this request</a>
311
+            <a
312
+              href="reports.php?action=report&amp;type=request&amp;id=<?= $RequestID ?>">report
313
+              this request</a>
309
             so that staff can fix it.
314
             so that staff can fix it.
310
             <?php } ?>
315
             <?php } ?>
311
             <input type="hidden" name="groupid"
316
             <input type="hidden" name="groupid"
314
         </tr>
319
         </tr>
315
 
320
 
316
         <!-- Bounty -->
321
         <!-- Bounty -->
317
-        <?php  } if ($NewRequest) { ?>
322
+        <?php
323
+          } if ($NewRequest) { ?>
318
         <tr id="voting">
324
         <tr id="voting">
319
           <td class="label">Bounty</td>
325
           <td class="label">Bounty</td>
320
           <td>
326
           <td>
328
               </option>
334
               </option>
329
             </select>
335
             </select>
330
             <input type="button" value="Preview" onclick="Calculate();" />
336
             <input type="button" value="Preview" onclick="Calculate();" />
331
-            <strong>The system deducts <?= ($RequestTax * 100) ?>% as tax</strong>
337
+            <strong>The system deducts <?= ($RequestTax * 100) ?>% as
338
+              tax</strong>
332
           </td>
339
           </td>
333
         </tr>
340
         </tr>
334
 
341
 
345
             <ul>
352
             <ul>
346
               <!-- @todo Return this feature
353
               <!-- @todo Return this feature
347
               <li><strong>Bounty:</strong> <span id="bounty_after_tax">90.00 MB</span></li> -->
354
               <li><strong>Bounty:</strong> <span id="bounty_after_tax">90.00 MB</span></li> -->
348
-              <li><strong>Uploaded:</strong> <span id="new_uploaded"><?= Format::get_size($LoggedUser['BytesUploaded']) ?></span></li>
349
-              <li><strong>Ratio:</strong> <span id="new_ratio"><?= Format::get_ratio_html($LoggedUser['BytesUploaded'], $LoggedUser['BytesDownloaded']) ?></span></li>
355
+              <li><strong>Uploaded:</strong> <span id="new_uploaded"><?= Format::get_size($LoggedUser['BytesUploaded']) ?></span>
356
+              </li>
357
+              <li><strong>Ratio:</strong> <span id="new_ratio"><?= Format::get_ratio_html($LoggedUser['BytesUploaded'], $LoggedUser['BytesDownloaded']) ?></span>
358
+              </li>
350
             </ul>
359
             </ul>
351
           </td>
360
           </td>
352
         </tr>
361
         </tr>

+ 19
- 12
sections/torrents/details.php View File

33
     }
33
     }
34
 }
34
 }
35
 
35
 
36
-$DisplayName = "<span dir=\"ltr\">$GroupName</span><br />";
36
+$DisplayName = "<span dir='ltr'>$GroupName</span><br />";
37
 $AltName = $GroupName; // Goes in the alt text of the image
37
 $AltName = $GroupName; // Goes in the alt text of the image
38
 $Title = $GroupName; // Goes in <title>
38
 $Title = $GroupName; // Goes in <title>
39
 $WikiBody = Text::full_format($WikiBody);
39
 $WikiBody = Text::full_format($WikiBody);
41
 $Artists = Artists::get_artist($GroupID);
41
 $Artists = Artists::get_artist($GroupID);
42
 
42
 
43
 if ($GroupNameRJ && $GroupNameRJ != $GroupName) {
43
 if ($GroupNameRJ && $GroupNameRJ != $GroupName) {
44
-    $DisplayName .= "<span dir=\"ltr\">$GroupNameRJ</span><br />";
44
+    $DisplayName .= "<span dir='ltr'>$GroupNameRJ</span><br />";
45
 }
45
 }
46
 
46
 
47
 if ($GroupNameJP && $GroupNameJP != $GroupName) {
47
 if ($GroupNameJP && $GroupNameJP != $GroupName) {
48
-    $DisplayName .= "<span dir=\"ltr\">$GroupNameJP</span><br />";
48
+    $DisplayName .= "<span dir='ltr'>$GroupNameJP</span><br />";
49
 }
49
 }
50
 
50
 
51
 if ($Artists) {
51
 if ($Artists) {
446
                 $ReporterID = $Report['ReporterID'];
446
                 $ReporterID = $Report['ReporterID'];
447
                 $Reporter = Users::user_info($ReporterID);
447
                 $Reporter = Users::user_info($ReporterID);
448
                 $ReporterName = $Reporter['Username'];
448
                 $ReporterName = $Reporter['Username'];
449
-                $ReportLinks = "<a href=\"user.php?id=$ReporterID\">$ReporterName</a> <a href=\"reportsv2.php?view=report&amp;id=$Report[ID]\">reported it</a>";
449
+                $ReportLinks = "<a href='user.php?id=$ReporterID'>$ReporterName</a> <a href='reportsv2.php?view=report&amp;id=$Report[ID]'>reported it</a>";
450
             } else {
450
             } else {
451
                 $ReportLinks = 'Someone reported it';
451
                 $ReportLinks = 'Someone reported it';
452
             }
452
             }
456
             } elseif (isset($Types['master'][$Report['Type']])) {
456
             } elseif (isset($Types['master'][$Report['Type']])) {
457
                 $ReportType = $Types['master'][$Report['Type']];
457
                 $ReportType = $Types['master'][$Report['Type']];
458
             } else {
458
             } else {
459
-                //There was a type but it wasn't an option!
459
+                // There was a type but it wasn't an option!
460
                 $ReportType = $Types['master']['other'];
460
                 $ReportType = $Types['master']['other'];
461
             }
461
             }
462
             $ReportInfo .= "
462
             $ReportInfo .= "
492
                 $Name = str_replace(' ', '&nbsp;', substr($Name, 0, $Spaces)) . substr($Name, $Spaces);
492
                 $Name = str_replace(' ', '&nbsp;', substr($Name, 0, $Spaces)) . substr($Name, $Spaces);
493
             }
493
             }
494
             $FileSize = substr($File, $NameEnd + 3, -3);
494
             $FileSize = substr($File, $NameEnd + 3, -3);
495
-            $FileTable .= sprintf("\n<tr class=\"row\"><td>%s</td><td class=\"number_column nobr\">%s</td></tr>", $Name, Format::get_size($FileSize));
495
+            $FileTable .= sprintf("\n<tr class='row'><td>%s</td><td class='number_column nobr'>%s</td></tr>", $Name, Format::get_size($FileSize));
496
         }
496
         }
497
     } else {
497
     } else {
498
         $FileListSplit = explode("\n", $FileList);
498
         $FileListSplit = explode("\n", $FileList);
499
         foreach ($FileListSplit as $File) {
499
         foreach ($FileListSplit as $File) {
500
             $FileInfo = Torrents::filelist_get_file($File);
500
             $FileInfo = Torrents::filelist_get_file($File);
501
-            $FileTable .= sprintf("\n<tr class=\"row\"><td>%s</td><td class=\"number_column nobr\">%s</td></tr>", $FileInfo['name'], Format::get_size($FileInfo['size']));
501
+            $FileTable .= sprintf("\n<tr class='row'><td>%s</td><td class='number_column nobr'>%s</td></tr>", $FileInfo['name'], Format::get_size($FileInfo['size']));
502
         }
502
         }
503
     }
503
     }
504
     $FileTable .= '
504
     $FileTable .= '
507
     $ExtraInfo = ''; // String that contains information on the torrent (e.g. format and encoding)
507
     $ExtraInfo = ''; // String that contains information on the torrent (e.g. format and encoding)
508
   $AddExtra = ''; // Separator between torrent properties
508
   $AddExtra = ''; // Separator between torrent properties
509
 
509
 
510
-  // similar to Torrents::torrent_info()
511
-    if ($Media && $GroupCategoryID != 5) {
510
+  // Similar to Torrents::torrent_info()
511
+    if ($Media) {
512
         $ExtraInfo.=display_str($Media);
512
         $ExtraInfo.=display_str($Media);
513
         $AddExtra=" / ";
513
         $AddExtra=" / ";
514
     }
514
     }
524
         $ExtraInfo.=$AddExtra.display_str($Resolution);
524
         $ExtraInfo.=$AddExtra.display_str($Resolution);
525
         $AddExtra=' / ';
525
         $AddExtra=' / ';
526
     }
526
     }
527
-    #if ($AudioFormat) { $ExtraInfo.=$AddExtra.display_str($AudioFormat); $AddExtra=' / '; }
527
+    /*
528
+    if ($AudioFormat) {
529
+      $ExtraInfo.=$AddExtra.display_str($AudioFormat);
530
+      $AddExtra=' / '; }
531
+      */
528
     /*
532
     /*
529
     if ($Language) {
533
     if ($Language) {
530
       if ($Subber && ($GroupCategoryID == 3 || $GroupCategoryID == 4)) {
534
       if ($Subber && ($GroupCategoryID == 3 || $GroupCategoryID == 4)) {
531
-        $ExtraInfo.=$AddExtra.display_str($Language.' ('.$Subber.')'); $AddExtra=' / ';
535
+        $ExtraInfo.=$AddExtra.display_str($Language.' ('.$Subber.')');
536
+        $AddExtra=' / ';
532
       } else {
537
       } else {
533
         $ExtraInfo.=$AddExtra.display_str($Language); $AddExtra=' / ';
538
         $ExtraInfo.=$AddExtra.display_str($Language); $AddExtra=' / ';
534
       }
539
       }
556
         $ExtraInfo .= $AddExtra.display_str('Unaligned');
561
         $ExtraInfo .= $AddExtra.display_str('Unaligned');
557
         $AddExtra=' / ';
562
         $AddExtra=' / ';
558
     }
563
     }
559
-    if (!$ExtraInfo || $GroupCategoryID == 5) {
564
+    if (!$ExtraInfo) {
560
         $ExtraInfo = $GroupName;
565
         $ExtraInfo = $GroupName;
561
         $AddExtra=' / ';
566
         $AddExtra=' / ';
562
     }
567
     }
737
     if (!empty($Description)) {
742
     if (!empty($Description)) {
738
         echo "\n<blockquote>".Text::full_format($Description).'</blockquote>';
743
         echo "\n<blockquote>".Text::full_format($Description).'</blockquote>';
739
     }
744
     }
745
+    
740
     /*
746
     /*
741
     if (!empty($MediaInfo) || $MediaInfo === 'nil') { # Kludge
747
     if (!empty($MediaInfo) || $MediaInfo === 'nil') { # Kludge
742
         $parsed = MediaInfo::parse($MediaInfo);
748
         $parsed = MediaInfo::parse($MediaInfo);
745
             echo $parsed;
751
             echo $parsed;
746
         } else {
752
         } else {
747
           */
753
           */
754
+
748
     echo "\n<blockquote>"; ?>
755
     echo "\n<blockquote>"; ?>
749
             <div class="spoilerContainer hideContainer">
756
             <div class="spoilerContainer hideContainer">
750
               <?php
757
               <?php

+ 94
- 31
sections/upload/upload_handle.php View File

13
 
13
 
14
 # Allow many uncompressed files,
14
 # Allow many uncompressed files,
15
 # e.g., http://academictorrents.com/details/5a447ff50062194bd58dd11c0fedead59e6d873c/tech
15
 # e.g., http://academictorrents.com/details/5a447ff50062194bd58dd11c0fedead59e6d873c/tech
16
-ini_set('max_file_uploads', 65535);
17
-define('MAX_FILENAME_LENGTH', 180);
16
+ini_set('max_file_uploads', 10000);
17
+define('MAX_FILENAME_LENGTH', 255);
18
 
18
 
19
 include(SERVER_ROOT.'/classes/validate.class.php');
19
 include(SERVER_ROOT.'/classes/validate.class.php');
20
 include(SERVER_ROOT.'/classes/feed.class.php');
20
 include(SERVER_ROOT.'/classes/feed.class.php');
30
 //*****************************************************************************//
30
 //*****************************************************************************//
31
 //--------------- Set $Properties array ---------------------------------------//
31
 //--------------- Set $Properties array ---------------------------------------//
32
 // This is used if the form doesn't validate, and when the time comes to enter //
32
 // This is used if the form doesn't validate, and when the time comes to enter //
33
-// it into the database.                                                       //
34
-// Haha wow god i'm trying to restrict the database to only have fields for    //
35
-// movies and not add anything for other categories but this is fucking dumb   //
33
+// it into the database.                 
34
+// @todo Do something about this mess
35
+//****************************************************************************//
36
 
36
 
37
 $Properties = [];
37
 $Properties = [];
38
 $Type = $Categories[(int)$_POST['type']];
38
 $Type = $Categories[(int)$_POST['type']];
44
 $Properties['TitleRJ'] = $_POST['title_rj'];
44
 $Properties['TitleRJ'] = $_POST['title_rj'];
45
 $Properties['TitleJP'] = $_POST['title_jp'];
45
 $Properties['TitleJP'] = $_POST['title_jp'];
46
 $Properties['Year'] = $_POST['year'];
46
 $Properties['Year'] = $_POST['year'];
47
-
48
 $Properties['Studio'] = isset($_POST['studio']) ? $_POST['studio'] : '';
47
 $Properties['Studio'] = isset($_POST['studio']) ? $_POST['studio'] : '';
49
-
50
 $Properties['Series'] = isset($_POST['series']) ? $_POST['series'] : '';
48
 $Properties['Series'] = isset($_POST['series']) ? $_POST['series'] : '';
51
-
52
 $Properties['CatalogueNumber'] = isset($_POST['catalogue']) ? $_POST['catalogue'] : '';
49
 $Properties['CatalogueNumber'] = isset($_POST['catalogue']) ? $_POST['catalogue'] : '';
53
 $Properties['Pages'] = isset($_POST['pages']) ? $_POST['pages'] : 0;
50
 $Properties['Pages'] = isset($_POST['pages']) ? $_POST['pages'] : 0;
54
 $Properties['Container'] = isset($_POST['container']) ? $_POST['container'] : '';
51
 $Properties['Container'] = isset($_POST['container']) ? $_POST['container'] : '';
55
-
56
 $Properties['Media'] = $_POST['media'];
52
 $Properties['Media'] = $_POST['media'];
57
-
58
 $Properties['Codec'] = isset($_POST['codec']) ? $_POST['codec'] : '';
53
 $Properties['Codec'] = isset($_POST['codec']) ? $_POST['codec'] : '';
54
+
59
 if (!($_POST['resolution'] ?? false)) {
55
 if (!($_POST['resolution'] ?? false)) {
60
     $_POST['resolution'] = $_POST['ressel'] ?? '';
56
     $_POST['resolution'] = $_POST['ressel'] ?? '';
61
 }
57
 }
58
+
62
 $Properties['Resolution'] = $_POST['resolution'] ?? '';
59
 $Properties['Resolution'] = $_POST['resolution'] ?? '';
63
 $Properties['AudioFormat'] = 'nil';
60
 $Properties['AudioFormat'] = 'nil';
64
 $Properties['Subbing'] = 'nil';
61
 $Properties['Subbing'] = 'nil';
68
 $Properties['Censored'] = (isset($_POST['censored'])) ? '1' : '0';
65
 $Properties['Censored'] = (isset($_POST['censored'])) ? '1' : '0';
69
 $Properties['Anonymous'] = (isset($_POST['anonymous'])) ? '1' : '0';
66
 $Properties['Anonymous'] = (isset($_POST['anonymous'])) ? '1' : '0';
70
 $Properties['Archive'] = (isset($_POST['archive']) && $_POST['archive'] !== '---') ? $_POST['archive'] : '';
67
 $Properties['Archive'] = (isset($_POST['archive']) && $_POST['archive'] !== '---') ? $_POST['archive'] : '';
68
+
71
 if (isset($_POST['library_image'])) {
69
 if (isset($_POST['library_image'])) {
72
     $Properties['LibraryImage'] = $_POST['library_image'];
70
     $Properties['LibraryImage'] = $_POST['library_image'];
73
 }
71
 }
72
+
74
 if (isset($_POST['tags'])) {
73
 if (isset($_POST['tags'])) {
75
     $Properties['TagList'] = implode(',', array_unique(explode(',', str_replace(' ', '', $_POST['tags']))));
74
     $Properties['TagList'] = implode(',', array_unique(explode(',', str_replace(' ', '', $_POST['tags']))));
76
 }
75
 }
76
+
77
 if (isset($_POST['image'])) {
77
 if (isset($_POST['image'])) {
78
     $Properties['Image'] = $_POST['image'];
78
     $Properties['Image'] = $_POST['image'];
79
 }
79
 }
122
 //******************************************************************************//
122
 //******************************************************************************//
123
 //--------------- Validate data in upload form ---------------------------------//
123
 //--------------- Validate data in upload form ---------------------------------//
124
 
124
 
125
+# torrents_group.CategoryID
125
 $Validate->SetFields(
126
 $Validate->SetFields(
126
     'type',
127
     'type',
127
     '1',
128
     '1',
130
     array('inarray' => array_keys($Categories))
131
     array('inarray' => array_keys($Categories))
131
 );
132
 );
132
 
133
 
134
+# @todo Remove the switch statement
133
 switch ($Type) {
135
 switch ($Type) {
134
     /*
136
     /*
135
   case 'Imaging':
137
   case 'Imaging':
136
     if (!isset($_POST['groupid']) || !$_POST['groupid']) {
138
     if (!isset($_POST['groupid']) || !$_POST['groupid']) {
137
-        $Validate->SetFields( # torrents.Media
139
+        # torrents.Media
140
+        $Validate->SetFields(
138
             'media',
141
             'media',
139
             '1',
142
             '1',
140
             'inarray',
143
             'inarray',
141
             'Please select a valid platform.',
144
             'Please select a valid platform.',
142
-            array('inarray'=>array_merge($Media, $MediaManga, $Platform))
145
+            array('inarray' => array_merge($Media, $MediaManga, $Platform))
143
         );
146
         );
144
 
147
 
145
-        $Validate->SetFields( # torrents.Container
148
+        # torrents.Container
149
+        $Validate->SetFields(
146
             'container',
150
             'container',
147
             '1',
151
             '1',
148
             'inarray',
152
             'inarray',
149
             'Please select a valid format.',
153
             'Please select a valid format.',
150
-            array('inarray'=>array_merge($Containers, $ContainersGames))
154
+            array('inarray' => array_merge($Containers, $ContainersGames))
151
         );
155
         );
152
     }
156
     }
153
 break;
157
 break;
155
 
159
 
156
 default:
160
 default:
157
     if (!isset($_POST['groupid']) || !$_POST['groupid']) {
161
     if (!isset($_POST['groupid']) || !$_POST['groupid']) {
158
-        $Validate->SetFields( # torrents_group.Name
162
+        # torrents_group.CatalogueNumber
163
+        $Validate->SetFields(
164
+            'catalogue',
165
+            '0',
166
+            'string',
167
+            'Accession Number must be between 0 and 50 characters.',
168
+            array('maxlength' => 50, 'minlength' => 0)
169
+        );
170
+
171
+        # torrents_group.Name
172
+        $Validate->SetFields(
159
             'title',
173
             'title',
160
             '1',
174
             '1',
161
             'string',
175
             'string',
162
-            'Torrent Title must be between 1 and 255 characters.',
163
-            array('maxlength'=>255, 'minlength'=>1)
176
+            'Torrent Title must be between 5 and 255 characters.',
177
+            array('maxlength' => 255, 'minlength' => 5)
164
         );
178
         );
165
 
179
 
166
-        $Validate->SetFields( # torrents_group.NameRJ
180
+        # torrents_group.NameRJ
181
+        $Validate->SetFields(
167
             'title_rj',
182
             'title_rj',
168
             '0',
183
             '0',
169
             'string',
184
             'string',
170
             'Organism must be between 0 and 255 characters.',
185
             'Organism must be between 0 and 255 characters.',
171
-            array('maxlength'=>255, 'minlength'=>0)
186
+            array('maxlength' => 255, 'minlength' => 0)
172
         );
187
         );
173
 
188
 
174
-        $Validate->SetFields( # torrents_group.NameJP
189
+        # torrents_group.NameJP
190
+        $Validate->SetFields(
175
             'title_jp',
191
             'title_jp',
176
             '0',
192
             '0',
177
             'string',
193
             'string',
178
             'Strain/Variety must be between 0 and 255 characters.',
194
             'Strain/Variety must be between 0 and 255 characters.',
179
-            array('maxlength'=>255, 'minlength'=>0)
195
+            array('maxlength' => 255, 'minlength' => 0)
196
+        );
197
+
198
+        # torrents_group.Studio
199
+        $Validate->SetFields(
200
+           'studio',
201
+            '0',
202
+            'string',
203
+            'Department/Lab must be between 0 and 100 characters.',
204
+            array('maxlength' => 100, 'minlength' => 0)
180
         );
205
         );
181
 
206
 
182
-        $Validate->SetFields( # torrents_group.Year
207
+        # torrents_group.Series
208
+        $Validate->SetFields(
209
+            'series',
210
+            '0',
211
+            'string',
212
+            'Location must be between 0 and 100 characters.',
213
+            array('maxlength' => 100, 'minlength' => 0)
214
+        );
215
+
216
+        # torrents_group.Year
217
+        $Validate->SetFields(
183
             'year',
218
             'year',
184
             '1',
219
             '1',
185
             'number',
220
             'number',
186
             'The year of the original release must be entered.',
221
             'The year of the original release must be entered.',
187
-            array('maxlength'=>4, 'minlength'=>4)
222
+            array('maxlength' => 4, 'minlength' => 4)
223
+        );
224
+
225
+        # torrents.Media
226
+        $Validate->SetFields(
227
+            'media',
228
+            '1',
229
+            'inarray',
230
+            'Please select a valid platform.',
231
+            array('inarray' => array_merge($Media, $MediaManga, $Platform))
188
         );
232
         );
189
 
233
 
190
-        $Validate->SetFields( # torrents_group.TagList
234
+        # torrents.Container
235
+        $Validate->SetFields(
236
+            'container',
237
+            '1',
238
+            'inarray',
239
+            'Please select a valid format.',
240
+            array('inarray' => array_merge($Containers, $ContainersGames))
241
+        );
242
+
243
+        # torrents_group.TagList
244
+        $Validate->SetFields(
191
             'tags',
245
             'tags',
192
             '1',
246
             '1',
193
             'string',
247
             'string',
194
             'You must enter at least five tags. Maximum length is 500 characters.',
248
             'You must enter at least five tags. Maximum length is 500 characters.',
195
-            array('maxlength'=>500, 'minlength'=>5)
249
+            array('maxlength' => 500, 'minlength' => 10)
196
         );
250
         );
197
 
251
 
198
-        $Validate->SetFields( # torrents_group.WikiImage
252
+        # torrents_group.WikiImage
253
+        $Validate->SetFields(
199
             'image',
254
             'image',
200
             '0',
255
             '0',
201
             'link',
256
             'link',
202
             'The image URL you entered was invalid.',
257
             'The image URL you entered was invalid.',
203
-            array('maxlength'=>255, 'minlength'=>10)
258
+            array('maxlength' => 255, 'minlength' => 10) # x.yz/a.bc
204
         );
259
         );
205
     }
260
     }
206
 
261
 
207
-    $Validate->SetFields( # torrents_group.WikiBody
262
+    # torrents_group.WikiBody
263
+    $Validate->SetFields(
208
         'album_desc',
264
         'album_desc',
209
         '1',
265
         '1',
210
         'string',
266
         'string',
211
-        'The description has a minimum length of 10 characters.',
212
-        array('maxlength'=>1000000, 'minlength'=>10)
267
+        'The description must be between 10 and 65535 characters.',
268
+        array('maxlength' => 65535, 'minlength' => 10)
269
+    );
270
+
271
+    # torrents_group.ID
272
+    $Validate->SetFields(
273
+        'groupid',
274
+        '0',
275
+        'number',
276
+        'Group ID was not numeric.'
213
     );
277
     );
214
-    #$Validate->SetFields('groupid', '0', 'number', 'Group ID was not numeric.');
215
 }
278
 }
216
 
279
 
217
 $Err = $Validate->ValidateForm($_POST); // Validate the form
280
 $Err = $Validate->ValidateForm($_POST); // Validate the form

+ 1
- 0
static/functions/bbcode.js View File

61
 }
61
 }
62
 
62
 
63
 function BBEditor(box) {
63
 function BBEditor(box) {
64
+  // @todo Integrate BioJS functions here
64
   if (box.previousSibling && box.previousSibling.className == 'bbcode_bar') return
65
   if (box.previousSibling && box.previousSibling.className == 'bbcode_bar') return
65
   let buttons = [
66
   let buttons = [
66
     {short:'B', name:'Bold', wrap:['[b]','[/b]']},
67
     {short:'B', name:'Bold', wrap:['[b]','[/b]']},

+ 1335
- 0
static/functions/biojs/ntseq.js
File diff suppressed because it is too large
View File


+ 1
- 1
static/functions/upload.js View File

43
       'studio': {},
43
       'studio': {},
44
       'series': {},
44
       'series': {},
45
       'media': {},
45
       'media': {},
46
-      'container': {},
46
+      'container_prot': {},
47
       'resolution': {},
47
       'resolution': {},
48
       'archive': {},
48
       'archive': {},
49
       'codec': {},
49
       'codec': {},

Loading…
Cancel
Save