mirror of
https://github.com/phpbb/phpbb.git
synced 2025-03-23 00:50:30 +01:00
[ticket/15506] Assign attachrow_template_vars before foreach
The attachrow_template_vars array needs to be defined once in front of the foreach instead of resetting the array on every iteration of the foreach. PHPBB3-15506
This commit is contained in:
parent
f26cf2dc1f
commit
350d4f3e6d
@ -727,10 +727,11 @@ function posting_gen_attachment_entry($attachment_data, &$filename_data, $show_a
|
||||
// We display the posted attachments within the desired order.
|
||||
($config['display_order']) ? krsort($attachment_data) : ksort($attachment_data);
|
||||
|
||||
$attachrow_template_vars = [];
|
||||
|
||||
foreach ($attachment_data as $count => $attach_row)
|
||||
{
|
||||
$hidden = '';
|
||||
$attachrow_template_vars = array();
|
||||
$attach_row['real_filename'] = utf8_basename($attach_row['real_filename']);
|
||||
|
||||
foreach ($attach_row as $key => $value)
|
||||
|
Loading…
x
Reference in New Issue
Block a user