diff --git a/classes/image_tools.class.php b/classes/image_tools.class.php
index afa9ad4c..b42a2fc3 100644
--- a/classes/image_tools.class.php
+++ b/classes/image_tools.class.php
@@ -66,7 +66,7 @@ public static function blacklisted($Url, $ShowError = true) {
foreach (self::$Blacklist as &$Value) {
if (stripos($Url, $Value)) {
$ParsedUrl = parse_url($Url);
- if($ShowError) {
+ if ($ShowError) {
error($ParsedUrl['host'] . ' is not an allowed image host. Please use a different host.');
}
return true;
diff --git a/sections/ajax/forum/index.php b/sections/ajax/forum/index.php
index 65d3002e..5bb791ec 100644
--- a/sections/ajax/forum/index.php
+++ b/sections/ajax/forum/index.php
@@ -14,7 +14,7 @@
if ($ForumCats === false) {
$DB->query("SELECT ID, Name FROM forums_categories");
$ForumCats = array();
- while (list($ID, $Name) = $DB->next_record()) {
+ while (list($ID, $Name) = $DB->next_record()) {
$ForumCats[$ID] = $Name;
}
$Cache->cache_value('forums_categories', $ForumCats, 0); //Inf cache.
@@ -50,7 +50,10 @@
$Forums = $DB->to_array('ID', MYSQLI_ASSOC, false);
foreach ($Forums as $ForumID => $Forum) {
if (count($Forum['SpecificRules'])) {
- $DB->query("SELECT ThreadID FROM forums_specific_rules WHERE ForumID = ".$ForumID);
+ $DB->query("
+ SELECT ThreadID
+ FROM forums_specific_rules
+ WHERE ForumID = $ForumID");
$ThreadIDs = $DB->collect('ThreadID');
$Forums[$ForumID]['SpecificRules'] = $ThreadIDs;
}
diff --git a/sections/ajax/takevote.php b/sections/ajax/takevote.php
index d45dbd89..4bd4200c 100644
--- a/sections/ajax/takevote.php
+++ b/sections/ajax/takevote.php
@@ -56,8 +56,8 @@
$Cache->cache_value('voted_albums_'.$LoggedUser['ID'], $UserVotes);
// Update the paired cache keys for "people who liked"
- // First update this album's paired votes. If this keys is magically not set,
- // our life just got a bit easier. We're only tracking paired votes on upvotes.
+ // First update this album's paired votes. If this keys is magically not set,
+ // our life just got a bit easier. We're only tracking paired votes on upvotes.
if ($Type == 'Up') {
$VotePairs = $Cache->get_value('vote_pairs_'.$GroupID, true);
if ($VotePairs !== false) {
@@ -135,15 +135,15 @@
}
$Cache->cache_value('votes_'.$GroupID, $GroupVotes);
- $DB->query("
+ $DB->query('
UPDATE torrents_votes
SET Total = GREATEST(0, Total - 1),
- Score = IFNULL(binomial_ci(GREATEST(0,Ups".($Type == 'Up' ? '-1' : '')."),GREATEST(0, Total)),0)".
+ Score = IFNULL(binomial_ci(GREATEST(0, Ups'.($Type == 'Up' ? '-1' : '').'),GREATEST(0, Total)), 0)'.
($Type == 'Up' ? ', Ups = GREATEST(0, Ups - 1)' : '')."
WHERE GroupID=$GroupID");
// Update paired cache keys
- // First update this album's paired votes. If this keys is magically not set,
- // our life just got a bit easier. We're only tracking paired votes on upvotes.
+ // First update this album's paired votes. If this keys is magically not set,
+ // our life just got a bit easier. We're only tracking paired votes on upvotes.
if ($Type == 'Up') {
$VotePairs = $Cache->get_value('vote_pairs_'.$GroupID, true);
if ($VotePairs !== false) {
diff --git a/sections/ajax/upload.php b/sections/ajax/upload.php
index 3a5b0960..8adbf2b4 100644
--- a/sections/ajax/upload.php
+++ b/sections/ajax/upload.php
@@ -8,8 +8,12 @@
$GenreTags = $Cache->get_value('genre_tags');
if (!$GenreTags) {
- $DB->query('SELECT Name FROM tags WHERE TagType=\'genre\' ORDER BY Name');
- $GenreTags = $DB->collect('Name');
+ $DB->query('
+ SELECT Name
+ FROM tags
+ WHERE TagType=\'genre\'
+ ORDER BY Name');
+ $GenreTags = $DB->collect('Name');
$Cache->cache_value('genre_tags', $GenreTags, 3600 * 24);
}
diff --git a/sections/artist/artist.php b/sections/artist/artist.php
index 0e2ba1dd..e5e29aa4 100644
--- a/sections/artist/artist.php
+++ b/sections/artist/artist.php
@@ -808,7 +808,7 @@ function compare($X, $Y) {
=$Votes?>
- if (check_perms('site_vote')) { ?>
+ if (check_perms('site_vote')) { ?>
+
} ?>
diff --git a/sections/better/transcode_beta.php b/sections/better/transcode_beta.php
index a3908001..cddc63cf 100644
--- a/sections/better/transcode_beta.php
+++ b/sections/better/transcode_beta.php
@@ -4,7 +4,7 @@
* $_GET['filter'] determines which torrents should be shown and can be empty/all (default), uploaded, snatched or seeding
* $_GET['target'] further filters which transcodes one would like to do and can be empty/any (default), v0, v2, 320 or all
* Here, 'any' means that at least one of the formats V0, V2 and 320 is missing and 'all' means that all of them are missing.
- * 'v0' etc mean that this specific format is missing (but others might be present).
+ * 'v0', etc. mean that this specific format is missing (but others might be present).
*
* Furthermore, there's $_GET['userid'] which allows to see the page as a different user would see it (specifically relevant for uploaded/snatched/seeding).
*/
@@ -304,7 +304,7 @@ function transcode_parse_groups($Groups) {
foreach ($Group['Editions'] as $RemIdent => $Edition) {
// TODO: point to the correct FLAC (?)
$FlacID = array_search(true, $Edition['FlacIDs']);
- $DisplayName = $ArtistNames . ''.$GroupName.'';
+ $DisplayName = $ArtistNames . "$GroupName";
if ($GroupYear > 0) {
$DisplayName .= " [$GroupYear]";
}
@@ -315,7 +315,7 @@ function transcode_parse_groups($Groups) {
$DisplayName .= ' ' . Format::torrent_label('Snatched!');
}
?>
-
>
+
>
DL
@@ -324,9 +324,9 @@ function transcode_parse_groups($Groups) {