From 44f05430fce417d93f1039ca272e38e91f9bcbc8 Mon Sep 17 00:00:00 2001 From: Git Date: Sat, 28 Dec 2013 08:01:02 +0000 Subject: [PATCH] Empty commit --- docs/CHANGES.txt | 9 +++++++++ sections/feeds/index.php | 21 ++++++++++----------- sections/torrents/details.php | 4 ++-- sections/torrents/peerlist.php | 2 +- 4 files changed, 22 insertions(+), 14 deletions(-) diff --git a/docs/CHANGES.txt b/docs/CHANGES.txt index 3b1813bd..e9b24615 100644 --- a/docs/CHANGES.txt +++ b/docs/CHANGES.txt @@ -1,5 +1,14 @@ CHANGE LOG +2013-12-28 by alderaan +Require the Text class in sections/feeds/index.php to fix broken RSS feeds. + +2013-12-28 by alderaan +Append "(this session)" to the "Up" column on torrent group peer lists + +2013-12-28 by alderaan +Fix display of bidirectional text (mixed LTR/RTL) for torrent group/artist names in the heading on torrent group pages. + 2013-12-25 by Ajax Custom date input for manual additions to the changelog diff --git a/sections/feeds/index.php b/sections/feeds/index.php index 2d772daf..81a6db5b 100644 --- a/sections/feeds/index.php +++ b/sections/feeds/index.php @@ -10,9 +10,9 @@ || empty($_GET['passkey']) || empty($_GET['user']) || !is_number($_GET['user']) - || strlen($_GET['authkey']) != 32 - || strlen($_GET['passkey']) != 32 - || strlen($_GET['auth']) != 32 + || strlen($_GET['authkey']) !== 32 + || strlen($_GET['passkey']) !== 32 + || strlen($_GET['auth']) !== 32 ) { $Feed->open_feed(); $Feed->channel('Blocked', 'RSS feed.'); @@ -22,9 +22,9 @@ $User = (int)$_GET['user']; -if (!$Enabled = $Cache->get_value('enabled_'.$User)) { +if (!$Enabled = $Cache->get_value("enabled_$User")) { require(SERVER_ROOT.'/classes/mysql.class.php'); - $DB=NEW DB_MYSQL; //Load the database wrapper + $DB = NEW DB_MYSQL; //Load the database wrapper $DB->query(" SELECT Enabled FROM users_main @@ -33,22 +33,21 @@ $Cache->cache_value("enabled_$User", $Enabled, 0); } -if (md5($User.RSS_HASH.$_GET['passkey']) != $_GET['auth'] || $Enabled != 1) { +if (md5($User.RSS_HASH.$_GET['passkey']) !== $_GET['auth'] || $Enabled != 1) { $Feed->open_feed(); $Feed->channel('Blocked', 'RSS feed.'); - - $Feed->close_feed(); die(); } +require(SERVER_ROOT.'/classes/text.class.php'); $Feed->open_feed(); switch ($_GET['feed']) { case 'feed_news': $Feed->channel('News', 'RSS feed for site news.'); if (!$News = $Cache->get_value('news')) { require(SERVER_ROOT.'/classes/mysql.class.php'); //Require the database wrapper - $DB=NEW DB_MYSQL; //Load the database wrapper + $DB = NEW DB_MYSQL; //Load the database wrapper $DB->query(" SELECT ID, @@ -63,7 +62,7 @@ } $Count = 0; foreach ($News as $NewsItem) { - list($NewsID,$Title,$Body,$NewsTime) = $NewsItem; + list($NewsID, $Title, $Body, $NewsTime) = $NewsItem; if (strtotime($NewsTime) >= time()) { continue; } @@ -96,7 +95,7 @@ foreach ($Blog as $BlogItem) { list($BlogID, $Author, $Title, $Body, $BlogTime, $ThreadID) = $BlogItem; if ($ThreadID) { - echo $Feed->item($Title, Text::strip_bbcode($Body), 'forums.php?action=viewthread&threadid='.$ThreadID, SITE_NAME.' Staff', '', '', $BlogTime); + echo $Feed->item($Title, Text::strip_bbcode($Body), "forums.php?action=viewthread&threadid=$ThreadID", SITE_NAME.' Staff', '', '', $BlogTime); } else { echo $Feed->item($Title, Text::strip_bbcode($Body), "blog.php#blog$BlogID", SITE_NAME.' Staff', '', '', $BlogTime); } diff --git a/sections/torrents/details.php b/sections/torrents/details.php index 238de1e0..264054d2 100644 --- a/sections/torrents/details.php +++ b/sections/torrents/details.php @@ -25,7 +25,7 @@ function compare($X, $Y) { $GroupTime, $GroupVanityHouse, $TorrentTags, $TorrentTagIDs, $TorrentTagUserIDs, $TagPositiveVotes, $TagNegativeVotes, $GroupFlags) = array_values($TorrentDetails); -$DisplayName = $GroupName; +$DisplayName = "$GroupName"; $AltName = $GroupName; // Goes in the alt text of the image $Title = $GroupName; // goes in $WikiBody = Text::full_format($WikiBody); @@ -33,7 +33,7 @@ function compare($X, $Y) { $Artists = Artists::get_artist($GroupID); if ($Artists) { - $DisplayName = '<span dir="ltr">'.Artists::display_artists($Artists, true) . "$DisplayName</span>"; + $DisplayName = Artists::display_artists($Artists, true) . "$DisplayName"; $AltName = display_str(Artists::display_artists($Artists, false)) . $AltName; $Title = $AltName; } diff --git a/sections/torrents/peerlist.php b/sections/torrents/peerlist.php index 2988ec70..7082cfad 100644 --- a/sections/torrents/peerlist.php +++ b/sections/torrents/peerlist.php @@ -44,7 +44,7 @@ <td>User</td> <td>Active</td> <td>Connectable</td> - <td class="number_column">Up</td> + <td class="number_column">Up (this session)</td> <td class="number_column">%</td> <td>Client</td> </tr>