From f64eb7dd0411c9ea8ab54eb746b90b24f63b4607 Mon Sep 17 00:00:00 2001 From: Marc Alexander Date: Sun, 17 Apr 2022 23:01:24 +0200 Subject: [PATCH] [ticket/17100] Move html for ext group selects from PHP files PHPBB3-17100 --- phpBB/adm/style/acp_attachments.html | 18 +++++++++++++++--- phpBB/includes/acp/acp_attachments.php | 26 ++++++++++++++++---------- 2 files changed, 31 insertions(+), 13 deletions(-) diff --git a/phpBB/adm/style/acp_attachments.html b/phpBB/adm/style/acp_attachments.html index c5f41b464e..529bdb7126 100644 --- a/phpBB/adm/style/acp_attachments.html +++ b/phpBB/adm/style/acp_attachments.html @@ -281,8 +281,14 @@
-
-
{GROUP_SELECT_OPTIONS}
+
+
+ +

@@ -315,7 +321,13 @@ {extensions.EXTENSION} - {extensions.GROUP_OPTIONS} + + + diff --git a/phpBB/includes/acp/acp_attachments.php b/phpBB/includes/acp/acp_attachments.php index 4e0db21d73..c03cda951a 100644 --- a/phpBB/includes/acp/acp_attachments.php +++ b/phpBB/includes/acp/acp_attachments.php @@ -452,11 +452,11 @@ class acp_attachments $cache->destroy('_extensions'); } - $template->assign_vars(array( + $template->assign_vars([ 'S_EXTENSIONS' => true, 'ADD_EXTENSION' => (isset($add_extension)) ? $add_extension : '', - 'GROUP_SELECT_OPTIONS' => (isset($_POST['add_extension_check'])) ? $this->group_select('add_group_select', $add_extension_group, 'extension_group') : $this->group_select('add_group_select', false, 'extension_group')) - ); + 'GROUP_SELECT_OPTIONS' => $this->group_select('add_group_select', $request->is_set_post('add_extension_check') ? $add_extension_group : false, 'extension_group'), + ]); $sql = 'SELECT * FROM ' . EXTENSIONS_TABLE . ' @@ -1470,8 +1470,6 @@ class acp_attachments { global $db, $user; - $group_select = ''; - return $group_select; }