diff --git a/classes/class_requests.php b/classes/class_requests.php index 4ba0cd3b..edd3086a 100644 --- a/classes/class_requests.php +++ b/classes/class_requests.php @@ -116,5 +116,6 @@ public static function get_requests($RequestIDs, $Return = true) { return $Matches; } } + } ?> diff --git a/sections/inbox/conversation.php b/sections/inbox/conversation.php index 6937a7d2..cae3022a 100644 --- a/sections/inbox/conversation.php +++ b/sections/inbox/conversation.php @@ -33,6 +33,7 @@ WHERE c.ID='$ConvID' AND UserID='$UserID'"); list($Subject, $Sticky, $UnRead, $ForwardedID) = $DB->next_record(); + $DB->query("SELECT um.ID, Username FROM pm_messages AS pm JOIN users_main AS um ON um.ID=pm.SenderID diff --git a/sections/login/index.php b/sections/login/index.php index 17883893..e2268a48 100644 --- a/sections/login/index.php +++ b/sections/login/index.php @@ -197,7 +197,7 @@ function log_attempt($UserID) { } } else { //No ban - $DB->query("INSERT INTO ip_bans + $DB->query("INSERT IGNORE INTO ip_bans (FromIP, ToIP, Reason) VALUES ('$IP','$IP', 'Automated ban per >60 failed login attempts')"); $A = substr($_SERVER['REMOTE_ADDR'], 0, strcspn($_SERVER['REMOTE_ADDR'], '.')); diff --git a/sections/requests/request.php b/sections/requests/request.php index 73d49a80..61448795 100644 --- a/sections/requests/request.php +++ b/sections/requests/request.php @@ -456,11 +456,31 @@ + +if(check_perms("users_mod")) { +$RequestLog = Requests::get_request_log($RequestID); + if($RequestLog) { +?> + + Request Log + + + + + + + +?> Description - full_format($Description)?> + full_format($Description);?> inserted_id(); + } else { $DB->query("UPDATE requests SET CategoryID = ".$CategoryID.", @@ -469,6 +470,7 @@ (".$LoggedUser['ID'].", '".sqltime()."', '".sqltime()."', ".$CategoryID.", '".db_string($Title)."', ".$Year.", '".db_string($Image)."', '".db_string($Description)."', '1', '".db_string($OCLC)."')"); $RequestID = $DB->inserted_id(); + } else { $DB->query("UPDATE requests SET CategoryID = ".$CategoryID.", @@ -487,6 +489,7 @@ (".$LoggedUser['ID'].", '".sqltime()."', '".sqltime()."', ".$CategoryID.", '".db_string($Title)."', '".db_string($Image)."', '".db_string($Description)."', '1', '".db_string($OCLC)."')"); $RequestID = $DB->inserted_id(); + } else { $DB->query("UPDATE requests SET CategoryID = ".$CategoryID.", diff --git a/sections/requests/takevote.php b/sections/requests/takevote.php index 81f5d2b0..680c6739 100644 --- a/sections/requests/takevote.php +++ b/sections/requests/takevote.php @@ -61,7 +61,7 @@ // Subtract amount from user $DB->query("UPDATE users_main SET Uploaded = (Uploaded - ".$Amount.") WHERE ID = ".$LoggedUser['ID']); $Cache->delete_value('user_stats_'.$LoggedUser['ID']); - + Requests::update_sphinx_requests($RequestID); echo 'success'; } elseif($LoggedUser['BytesUploaded'] < $Amount) {