From 39956ded1f476188749fd8365549c0f83ec72f7a Mon Sep 17 00:00:00 2001 From: Git Date: Sun, 16 Jun 2013 08:01:11 +0000 Subject: [PATCH] Empty commit --- classes/misc.class.php | 20 ++++++++ design/privateheader.php | 1 + docs/CHANGES.txt | 6 +++ gazelle.sql | 10 ++-- sections/ajax/artist.php | 27 ++++++++++- sections/feeds/index.php | 16 ++++++ sections/tools/managers/change_log.php | 67 +++++++++++++------------- sections/tools/tools.php | 2 +- static/styles/anorex/style.css | 15 ++++++ static/styles/dark_ambient/style.css | 20 ++++++-- static/styles/kuro/style.css | 15 ++++++ static/styles/layer_cake/style.css | 15 ++++++ static/styles/layer_cake/style2.css | 15 ++++++ static/styles/minimal/style.css | 10 +++- static/styles/minimal/style2.css | 10 +++- static/styles/mono/style.css | 10 +++- static/styles/postmod/style.css | 17 ++++++- static/styles/proton/style.css | 13 ++++- static/styles/white.cd/style.css | 16 +++++- 19 files changed, 254 insertions(+), 51 deletions(-) diff --git a/classes/misc.class.php b/classes/misc.class.php index 8befd92e..c56c22dc 100644 --- a/classes/misc.class.php +++ b/classes/misc.class.php @@ -447,6 +447,26 @@ public static function display_array($Array, $Escape = array()) { return $Array; } + /** + * Searches for a key/value pair in an array. + * + * @return array of results + */ + public static function search_array($Array, $Key, $Value) { + $Results = array(); + if (is_array($Array)) + { + if (isset($Array[$Key]) && $Array[$Key] == $Value) { + $Results[] = $Array; + } + + foreach ($Array as $subarray) { + $Results = array_merge($Results, self::search_array($subarray, $Key, $Value)); + } + } + return $Results; + } + /** * Check for a : in the beginning of a torrent meta data string * to see if it's stored in the old base64-encoded format diff --git a/design/privateheader.php b/design/privateheader.php index 5c0e52d0..8189c2ce 100644 --- a/design/privateheader.php +++ b/design/privateheader.php @@ -19,6 +19,7 @@ + $Group) { extract(Torrents::array_group($Group)); + foreach($Artists as &$Artist) { + $Artist['id'] = (int) $Artist['id']; + $Artist['aliasid'] = (int) $Artist['aliasid']; + } + + foreach($ExtendedArtists as &$ArtistGroup) { + foreach($ArtistGroup as &$Artist) { + $Artist['id'] = (int) $Artist['id']; + $Artist['aliasid'] = (int) $Artist['aliasid']; + + } + } + + $Found = Misc::search_array($Artists, 'id', $ArtistID); + if (isset($OnlyArtistReleases) && empty($Found)) { + continue; + } + $GroupVanityHouse = $Importances[$GroupID]['VanityHouse']; $TagList = explode(' ',str_replace('_','.',$TagList)); @@ -224,7 +246,10 @@ function compare($X, $Y) { 'wikiImage' => $WikiImage, 'groupVanityHouse' => $GroupVanityHouse == 1, 'hasBookmarked' => Bookmarks::has_bookmarked('torrent', $GroupID), - 'torrent' => $InnerTorrents + 'artists' => $Artists, + 'extendedArtists' => $ExtendedArtists, + 'torrent' => $InnerTorrents, + ); } diff --git a/sections/feeds/index.php b/sections/feeds/index.php index 7c519707..557c0325 100644 --- a/sections/feeds/index.php +++ b/sections/feeds/index.php @@ -102,6 +102,22 @@ } } break; + case 'feed_changelog': + $Feed->channel('Gazelle Change Log', 'RSS feed for Gazelle\'s changelog.'); + if (!$Changelog = $Cache->get_value('changelog')) { + require(SERVER_ROOT.'/classes/mysql.class.php'); + require(SERVER_ROOT.'/classes/misc.class.php'); + + $DB = NEW DB_MYSQL; + $DB->query("SELECT Message, Author, Date(Time) FROM changelog ORDER BY Time DESC LIMIT 20"); + $Changelog = $DB->to_array(); + $Cache->cache_value('changelog', $Changelog, 86400); + } + foreach ($Changelog as $Change) { + list($Message, $Author, $Date) = $Change; + echo $Feed->item($Date . " by " . $Author, $Message, 'tools.php?action=change_log', SITE_NAME.' Staff','','',$Date); + } + break; case 'torrents_all': $Feed->channel('All Torrents', 'RSS feed for all new torrent uploads.'); $Feed->retrieve('torrents_all',$_GET['authkey'],$_GET['passkey']); diff --git a/sections/tools/managers/change_log.php b/sections/tools/managers/change_log.php index 9f30ef86..2ab5a943 100644 --- a/sections/tools/managers/change_log.php +++ b/sections/tools/managers/change_log.php @@ -45,49 +45,50 @@ echo "\t\t$Pages\n"; ?> -
-
-
-
-
- Manually submit a new change to the change log +
+
+ Manually submit a new change to the change log +
+
+ + + +
+ Commit message:
+
-
- - - -

- -

+
+ Author:
+ +
+
-
- -
+ +
+
-
-
- by +
+
+ by - -
- - - -
- Delete -
+ +
+ + + +
+ Delete +
-
-
-
- -
- +
+ +
+
diff --git a/sections/tools/tools.php b/sections/tools/tools.php index 857ee67b..91f6bca8 100644 --- a/sections/tools/tools.php +++ b/sections/tools/tools.php @@ -33,7 +33,7 @@ Label aliases - Change Log + Change log
diff --git a/static/styles/anorex/style.css b/static/styles/anorex/style.css index 4ae74c72..4cfa24fc 100644 --- a/static/styles/anorex/style.css +++ b/static/styles/anorex/style.css @@ -364,6 +364,13 @@ p.min_padding { border: 1px solid #65430F; } +.box2 { + font-size: 8pt; + background-color: #DCB881; + border: 1px solid #65430F; + margin-bottom: 10px; +} + .pad h3, .pad h4, .padbox h3, .padbox h4 { margin-top: 0px; padding-top: 0px; @@ -809,3 +816,11 @@ ul .invitetree { .brackets:before, .brackets:after { color: #492802; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} diff --git a/static/styles/dark_ambient/style.css b/static/styles/dark_ambient/style.css index 1086a493..09f4bf36 100644 --- a/static/styles/dark_ambient/style.css +++ b/static/styles/dark_ambient/style.css @@ -166,7 +166,8 @@ select { } .main_column .pad, -.sidebar .pad { +.sidebar .pad, +.box2 .pad { padding: 10px !important; } @@ -511,7 +512,8 @@ margin-left:20px; z-index:3; } -#content .box h2 { +#content .box h2, +#content .box2 h2 { background: none; margin: 0; padding: 0; @@ -988,14 +990,16 @@ strong.quoteheader{color: #878787;} } .sidebar .box .head, -.main_column .box .head { +.main_column .box .head, +.box2 .head { background-color: #212121; padding: 10px !important; border-bottom: 1px solid #1a1a1a; } .sidebar .box, -.main_column .box { +.main_column .box, +.box2 { background-color: #212121; border: 1px solid #1a1a1a; margin: 0 0 20px 0; @@ -2000,3 +2004,11 @@ tr.torrent .bookmark > a:after { content:""; } .group_image + .group_info { margin: 0; padding: 0 5px; display: table-cell; vertical-align: middle; height: 90px; } #torrents .group_image + .group_info { width: 450px; } #top10 .group_image + .group_info { width: 585px; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} diff --git a/static/styles/kuro/style.css b/static/styles/kuro/style.css index 55a23cae..4c538713 100644 --- a/static/styles/kuro/style.css +++ b/static/styles/kuro/style.css @@ -493,6 +493,13 @@ p.min_padding { border: 1px solid #303030; } +.box2 { + font-size: 8pt; + background-color: #282828; + border: 1px solid #303030; + margin-bottom: 10px; +} + .pad h3,.pad h4,.padbox h3,.padbox h4 { margin-top: 0px; padding-top: 0px; @@ -907,3 +914,11 @@ tr.torrent .bookmark > a:after { color:#999; } .top10_quantity_links .brackets:after { color: #999; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} diff --git a/static/styles/layer_cake/style.css b/static/styles/layer_cake/style.css index fca45f83..b254e1b3 100644 --- a/static/styles/layer_cake/style.css +++ b/static/styles/layer_cake/style.css @@ -376,6 +376,13 @@ p.min_padding { border: 1px solid #666666; } +.box2 { + margin-bottom: 10px; + font-size: 8pt; + background-color: #EAEAEA; + border: 1px solid #666666; +} + .pad h3, .pad h4, .padbox h3, .padbox h4 { margin-top: 0px; padding-top: 0px; @@ -784,3 +791,11 @@ tr.torrent .bookmark > a:before { tr.torrent .bookmark > a:after { color: black; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} diff --git a/static/styles/layer_cake/style2.css b/static/styles/layer_cake/style2.css index c59f7f58..c48b2262 100644 --- a/static/styles/layer_cake/style2.css +++ b/static/styles/layer_cake/style2.css @@ -353,6 +353,13 @@ p.min_padding { border: 1px solid #666666; } +.box2 { + font-size: 8pt; + background-color: #EAEAEA; + border: 1px solid #666666; + margin-bottom: 10px; +} + .pad h3, .pad h4, .padbox h3, .padbox h4 { margin-top: 0px; padding-top: 0px; @@ -736,3 +743,11 @@ ul .invitetree { z-index:1002; overflow: auto; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} diff --git a/static/styles/minimal/style.css b/static/styles/minimal/style.css index 45b671f9..00dea596 100644 --- a/static/styles/minimal/style.css +++ b/static/styles/minimal/style.css @@ -18,7 +18,7 @@ input#file, input[type="file"]{color:#000} textarea#quickpost{margin:0; padding:0} /* GENERAL */ -.box, #content table tr td{background: #373737; margin-bottom: 15px;} +.box, .box2, #content table tr td{background: #373737; margin-bottom: 15px;} .pad{padding: 10px;} .sidebar .box{position:relative} @@ -554,3 +554,11 @@ tr.torrent .bookmark > a:after { content: ""; } .group_image + .group_info { margin: 0; padding: 0 5px; display: table-cell; vertical-align: middle; height: 90px; } #torrents .group_image + .group_info { width: 520px; } #top10 .group_image + .group_info { width: 585px; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} diff --git a/static/styles/minimal/style2.css b/static/styles/minimal/style2.css index f53dcca1..4d17667d 100644 --- a/static/styles/minimal/style2.css +++ b/static/styles/minimal/style2.css @@ -18,7 +18,7 @@ input#file, input[type="file"]{color:#fff} textarea#quickpost{margin:0; padding:0} /* GENERAL */ -.box, #content table tr td{background:#373737; margin-bottom:15px} +.box, .box2, #content table tr td{background:#373737; margin-bottom:15px} .pad{padding:10px} .sidebar .box{position:relative} @@ -477,3 +477,11 @@ h3{margin:10px 0} .group_image + .group_info { margin: 0; padding: 0 5px; display: table-cell; vertical-align: middle; height: 90px; } #torrents .group_image + .group_info { width: 520px; } #top10 .group_image + .group_info { width: 585px; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} diff --git a/static/styles/mono/style.css b/static/styles/mono/style.css index 4e958f57..242d231e 100644 --- a/static/styles/mono/style.css +++ b/static/styles/mono/style.css @@ -502,7 +502,7 @@ ul.collage_images li a:hover img { width: 100% !important; } -table[width="100%"],.box,.torrent_table,#log_table,#request_table,#collages,.forum_index,table.border,.linkbox+table,form#messageform table ,.main_column table ,form[action="user.php"] table,table.staff,#userhistory table { +table[width="100%"],.box,.box2,.torrent_table,#log_table,#request_table,#collages,.forum_index,table.border,.linkbox+table,form#messageform table ,.main_column table ,form[action="user.php"] table,table.staff,#userhistory table { margin-bottom: 20px; padding: 10px; background: #fff; @@ -1337,3 +1337,11 @@ form.manage_form[name=friends] .left input[type=submit] { .group_image + .group_info { margin: 0; padding: 0 5px; display: table-cell; vertical-align: middle; height: 90px; } #torrents .group_image + .group_info { width: 450px; } #top10 .group_image + .group_info { width: 585px; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} diff --git a/static/styles/postmod/style.css b/static/styles/postmod/style.css index 24ffc06e..f72dfdf9 100644 --- a/static/styles/postmod/style.css +++ b/static/styles/postmod/style.css @@ -96,7 +96,8 @@ h1 a:hover, h2 a:hover, h3 a:hover { text-decoration: underline; } -.box h1, .box h2, .box h3, .box h4 { +.box h1, .box h2, .box h3, .box h4 +.box2 h1, .box2 h2, .box2 h3, .box2 h4 { color: #000; } @@ -524,6 +525,12 @@ p.min_padding { background-color: #F7F6F2; } +.box2 { + font-size: 10pt; + background-color: #F7F6F2; + margin-bottom: 10px; +} + .pad h3, .pad h4, .padbox h3, .padbox h4 { margin-top: 0px; padding-top: 0px; @@ -1068,3 +1075,11 @@ tr.torrent .bookmark > a:after { #userinfo_username .brackets:after { content: "]"; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} diff --git a/static/styles/proton/style.css b/static/styles/proton/style.css index 215d02a3..dc611c43 100644 --- a/static/styles/proton/style.css +++ b/static/styles/proton/style.css @@ -171,6 +171,7 @@ select { .main_column .pad, .sidebar .pad, +.box2 .pad, #blog .pad { padding: 10px !important; } @@ -1131,6 +1132,7 @@ tr.torrent .bookmark > a:after { .sidebar .box .head, .main_column .box .head, +.box2 .head, #blog .box .head { background-color: #f0f0f0; padding: 10px !important; @@ -1150,7 +1152,8 @@ tr.torrent .bookmark > a:after { .sidebar .box, .main_column .box:not(.forum_post), -#blog .box { +#blog .box, +.box2 { background-color: #f5f5f5; border: 1px solid #dcdcdc; margin: 0 0 20px 0; @@ -2044,3 +2047,11 @@ tr.torrent .bookmark > a:after { background-size: 90px; color: transparent; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} diff --git a/static/styles/white.cd/style.css b/static/styles/white.cd/style.css index 043bea2b..a37955e9 100644 --- a/static/styles/white.cd/style.css +++ b/static/styles/white.cd/style.css @@ -404,12 +404,12 @@ textarea { * html .main_column { overflow-x:hidden; } -.box { +.box, .box2 { border-bottom:1px solid #eee; margin-bottom:20px; padding-bottom:20px; } -.box:last-child { +.box:last-child, .box2:last-child { border-bottom:0; } .head strong { @@ -778,3 +778,15 @@ tr.torrent .bookmark > a:after { content: ""; } .top10_quantity_links .brackets:after { color: #666; } + +.field_div { + margin-bottom: 10px; +} + +.edit_changelog textarea { + width: 600px; +} + +.field_div#cl_message { + margin-bottom: 0px; +}