mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
[ticket/9944] Extension groups naming don't use users' language in ACP
Only happens on boards which were installed with 3.0.8 PHPBB3-9944
This commit is contained in:
parent
afc856417f
commit
4890006cbb
2 changed files with 34 additions and 9 deletions
|
@ -916,6 +916,8 @@ function database_update_info()
|
|||
'3.0.7-PL1' => array(),
|
||||
// No changes from 3.0.8-RC1 to 3.0.8
|
||||
'3.0.8-RC1' => array(),
|
||||
// No changes from 3.0.8 to 3.0.9-RC1
|
||||
'3.0.8' => array(),
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -1858,6 +1860,29 @@ function change_database_data(&$no_updates, $version)
|
|||
// No changes from 3.0.8-RC1 to 3.0.8
|
||||
case '3.0.8-RC1':
|
||||
break;
|
||||
|
||||
// Changes from 3.0.8 to 3.0.9-RC1
|
||||
case '3.0.8':
|
||||
// Update file extension group names to use language strings, again.
|
||||
$sql = 'SELECT group_id, group_name
|
||||
FROM ' . EXTENSION_GROUPS_TABLE . '
|
||||
WHERE group_name ' . $db->sql_like_expression('EXT_GROUP_' . $db->any_char);
|
||||
$result = $db->sql_query($sql);
|
||||
while ($row = $db->sql_fetchrow($result))
|
||||
{
|
||||
$sql_ary = array(
|
||||
'group_name' => substr($row['group_name'], 10), // Strip off 'EXT_GROUP_'
|
||||
);
|
||||
|
||||
$sql = 'UPDATE ' . EXTENSION_GROUPS_TABLE . '
|
||||
SET ' . $db->sql_build_array('UPDATE', $sql_ary) . '
|
||||
WHERE group_id = ' . $row['group_id'];
|
||||
_sql($sql, $errored, $error_ary);
|
||||
}
|
||||
$db->sql_freeresult($result);
|
||||
|
||||
$no_updates = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -743,15 +743,15 @@ INSERT INTO phpbb_reports_reasons (reason_title, reason_description, reason_orde
|
|||
INSERT INTO phpbb_reports_reasons (reason_title, reason_description, reason_order) VALUES ('other', '{L_REPORT_OTHER}', 4);
|
||||
|
||||
# -- extension_groups
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('{L_EXT_GROUP_IMAGES}', 1, 1, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('{L_EXT_GROUP_ARCHIVES}', 0, 1, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('{L_EXT_GROUP_PLAIN_TEXT}', 0, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('{L_EXT_GROUP_DOCUMENTS}', 0, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('{L_EXT_GROUP_REAL_MEDIA}', 3, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('{L_EXT_GROUP_WINDOWS_MEDIA}', 2, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('{L_EXT_GROUP_FLASH_FILES}', 5, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('{L_EXT_GROUP_QUICKTIME_MEDIA}', 6, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('{L_EXT_GROUP_DOWNLOADABLE_FILES}', 0, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('IMAGES', 1, 1, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('ARCHIVES', 0, 1, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('PLAIN_TEXT', 0, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('DOCUMENTS', 0, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('REAL_MEDIA', 3, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('WINDOWS_MEDIA', 2, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('FLASH_FILES', 5, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('QUICKTIME_MEDIA', 6, 0, 1, '', 0, '');
|
||||
INSERT INTO phpbb_extension_groups (group_name, cat_id, allow_group, download_mode, upload_icon, max_filesize, allowed_forums) VALUES ('DOWNLOADABLE_FILES', 0, 0, 1, '', 0, '');
|
||||
|
||||
# -- extensions
|
||||
INSERT INTO phpbb_extensions (group_id, extension) VALUES (1, 'gif');
|
||||
|
|
Loading…
Add table
Reference in a new issue