diff --git a/phpBB/adm/style/acp_users_prefs.html b/phpBB/adm/style/acp_users_prefs.html
index 90db62984e..9439f0cf03 100644
--- a/phpBB/adm/style/acp_users_prefs.html
+++ b/phpBB/adm/style/acp_users_prefs.html
@@ -52,10 +52,7 @@
-
-
-
-
+
{L_BOARD_DATE_FORMAT_EXPLAIN}
diff --git a/phpBB/adm/style/timezone.js b/phpBB/adm/style/timezone.js
new file mode 100644
index 0000000000..d02c965ab5
--- /dev/null
+++ b/phpBB/adm/style/timezone.js
@@ -0,0 +1,29 @@
+function phpbb_switch_tz_date(keep_selection)
+{
+ var timezone_groups = document.getElementById("timezone");
+ for (var i = 0; i < timezone_groups.childElementCount; i++) {
+ if (timezone_groups.children[i].tagName == "OPTGROUP" &&
+ timezone_groups.children[i].label != document.getElementById("tz_date").value)
+ {
+ timezone_groups.children[i].style.display = "none";
+ }
+ else if (timezone_groups.children[i].tagName == "OPTGROUP")
+ {
+ // Display other options
+ timezone_groups.children[i].style.display = "block";
+ }
+ }
+ if (typeof keep_selection !== 'undefined')
+ {
+ if (!keep_selection)
+ {
+ timezone_groups.children[0].selected = true;
+ }
+ }
+}
+
+function phpbb_enable_tz_dates()
+{
+ var tz_select_date = document.getElementById("tz_select_date");
+ tz_select_date.style.display = "block";
+}
diff --git a/phpBB/adm/style/timezone_option.html b/phpBB/adm/style/timezone_option.html
new file mode 100644
index 0000000000..12e6e3700a
--- /dev/null
+++ b/phpBB/adm/style/timezone_option.html
@@ -0,0 +1,20 @@
+
+
+
+ -
+
+
+
+ -
+
+
+
+
+
+
diff --git a/phpBB/includes/acp/acp_users.php b/phpBB/includes/acp/acp_users.php
index b863a9ed80..949109abaf 100644
--- a/phpBB/includes/acp/acp_users.php
+++ b/phpBB/includes/acp/acp_users.php
@@ -1639,6 +1639,7 @@ class acp_users
${'s_sort_' . $sort_option . '_dir'} .= '';
}
+ $tz_select = tz_select($data['tz'], true, false);
$template->assign_vars(array(
'S_PREFS' => true,
'S_JABBER_DISABLED' => ($config['jab_enable'] && $user_row['user_jabber'] && @extension_loaded('xml')) ? false : true,
@@ -1678,7 +1679,8 @@ class acp_users
'S_LANG_OPTIONS' => language_select($data['lang']),
'S_STYLE_OPTIONS' => style_select($data['style']),
- 'S_TZ_OPTIONS' => tz_select($data['tz'], true),
+ 'S_TZ_OPTIONS' => $tz_select['tz_select'],
+ 'S_TZ_DATE_OPTIONS' => $tz_select['tz_dates'],
)
);
diff --git a/phpBB/language/en/acp/common.php b/phpBB/language/en/acp/common.php
index dc35969955..5cebcc89d7 100644
--- a/phpBB/language/en/acp/common.php
+++ b/phpBB/language/en/acp/common.php
@@ -401,6 +401,8 @@ $lang = array_merge($lang, array(
'STATISTIC' => 'Statistic',
'STATISTIC_RESYNC_OPTIONS' => 'Resynchronise or reset statistics',
+ 'TIMEZONE_INVALID' => 'The timezone you selected is invalid.',
+ 'TIMEZONE_SELECTED' => '(currently selected)',
'TOPICS_PER_DAY' => 'Topics per day',
'UPLOAD_DIR_SIZE' => 'Size of posted attachments',