aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--phpBB/adm/style/acp_attachments.html13
-rw-r--r--phpBB/includes/acp/acp_attachments.php7
2 files changed, 13 insertions, 7 deletions
diff --git a/phpBB/adm/style/acp_attachments.html b/phpBB/adm/style/acp_attachments.html
index 868e256ef5..f92971bc93 100644
--- a/phpBB/adm/style/acp_attachments.html
+++ b/phpBB/adm/style/acp_attachments.html
@@ -424,8 +424,17 @@
<!-- BEGIN attachments -->
<tr>
<td>
- <!-- IF attachments.S_IN_MESSAGE -->{L_EXTENSION_GROUP}{L_COLON} <strong><!-- IF attachments.EXT_GROUP_NAME -->{attachments.EXT_GROUP_NAME}<!-- ELSE -->{L_NO_EXT_GROUP}<!-- ENDIF --></strong><br />{attachments.L_DOWNLOAD_COUNT}<br />{L_IN} {L_PRIVATE_MESSAGE}
- <!-- ELSE --><a href="{attachments.U_FILE}" style="font-weight: bold;">{attachments.REAL_FILENAME}</a><br /><!-- IF attachments.COMMENT -->{attachments.COMMENT}<br /><!-- ENDIF -->{attachments.L_DOWNLOAD_COUNT}<br />{L_TOPIC}{L_COLON} <a href="{attachments.U_VIEW_TOPIC}">{attachments.TOPIC_TITLE}</a><!-- ENDIF -->
+ <!-- IF ! attachments.S_IN_MESSAGE -->{# File info of attachments in private messages is hidden #}
+ <a href="{attachments.U_FILE}" style="font-weight: bold;">{attachments.REAL_FILENAME}</a><br />
+ {L_EXTENSION_GROUP}{L_COLON} <strong><!-- IF attachments.EXT_GROUP_NAME -->{attachments.EXT_GROUP_NAME}<!-- ELSE -->{L_NO_EXT_GROUP}<!-- ENDIF --></strong><br />
+ <!-- ENDIF -->
+ {attachments.L_DOWNLOAD_COUNT}<br />
+ <!-- IF attachments.S_IN_MESSAGE -->
+ {L_IN} {L_PRIVATE_MESSAGE}
+ <!-- IF attachments.COMMENT -->{attachments.COMMENT}<br /><!-- ENDIF -->
+ <!-- ELSE -->
+ {L_TOPIC}{L_COLON} <a href="{attachments.U_VIEW_TOPIC}">{attachments.TOPIC_TITLE}</a>
+ <!-- ENDIF -->
</td>
<td>{attachments.FILETIME}<br />{L_POST_BY_AUTHOR} {attachments.ATTACHMENT_POSTER}</td>
<td class="centered-text">{attachments.FILESIZE}</td>
diff --git a/phpBB/includes/acp/acp_attachments.php b/phpBB/includes/acp/acp_attachments.php
index 94e36a26dc..72cb639185 100644
--- a/phpBB/includes/acp/acp_attachments.php
+++ b/phpBB/includes/acp/acp_attachments.php
@@ -1244,16 +1244,13 @@ class acp_attachments
$display_cat = isset($extensions[$row['extension']]['display_cat']) ? $extensions[$row['extension']]['display_cat'] : ATTACHMENT_CATEGORY_NONE;
$l_downloaded_viewed = ($display_cat == ATTACHMENT_CATEGORY_NONE) ? 'DOWNLOAD_COUNTS' : 'VIEWED_COUNTS';
- // Capitalises the group name and checks if its key exists in the language file
- $up_group_name = utf8_strtoupper($extensions[$row['extension']]['group_name']);
-
$template->assign_block_vars('attachments', array(
'ATTACHMENT_POSTER' => get_username_string('full', (int) $row['poster_id'], (string) $row['username'], (string) $row['user_colour'], (string) $row['username']),
'FILESIZE' => get_formatted_filesize((int) $row['filesize']),
'FILETIME' => $user->format_date((int) $row['filetime']),
- 'REAL_FILENAME' => (!$row['in_message']) ? utf8_basename((string) $row['real_filename']) : '',
+ 'REAL_FILENAME' => utf8_basename((string) $row['real_filename']),
'PHYSICAL_FILENAME' => utf8_basename((string) $row['physical_filename']),
- 'EXT_GROUP_NAME' => $this->lang->is_set('EXT_GROUP_' . $up_group_name) ? $this->lang->lang('EXT_GROUP_' . $up_group_name) : $extensions[$row['extension']]['group_name'],
+ 'EXT_GROUP_NAME' => $this->lang->is_set('EXT_GROUP_' . $extensions[$row['extension']]['group_name']) ? $this->lang->lang('EXT_GROUP_' . $extensions[$row['extension']]['group_name']) : $extensions[$row['extension']]['group_name'],
'COMMENT' => $comment,
'TOPIC_TITLE' => (!$row['in_message']) ? (string) $row['topic_title'] : '',
'ATTACH_ID' => (int) $row['attach_id'],