aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/functions_profile_fields.php
diff options
context:
space:
mode:
authorNils Adermann <naderman@naderman.de>2008-03-06 19:31:03 +0000
committerNils Adermann <naderman@naderman.de>2008-03-06 19:31:03 +0000
commitf115ab68a52fd3b163093d71319572251d0b1070 (patch)
tree41cc8c60f46c9d5b1122e5cb07b05dbb062e4a8e /phpBB/includes/functions_profile_fields.php
parentcf17b13c98e742dda879ea509dc67c1a8c0f0989 (diff)
downloadforums-f115ab68a52fd3b163093d71319572251d0b1070.tar
forums-f115ab68a52fd3b163093d71319572251d0b1070.tar.gz
forums-f115ab68a52fd3b163093d71319572251d0b1070.tar.bz2
forums-f115ab68a52fd3b163093d71319572251d0b1070.tar.xz
forums-f115ab68a52fd3b163093d71319572251d0b1070.zip
Custom profile fields with date type should be timezone independend [Bug #15003]
git-svn-id: file:///svn/phpbb/trunk@8425 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/functions_profile_fields.php')
-rw-r--r--phpBB/includes/functions_profile_fields.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/phpBB/includes/functions_profile_fields.php b/phpBB/includes/functions_profile_fields.php
index bd344a801d..cccd0b758f 100644
--- a/phpBB/includes/functions_profile_fields.php
+++ b/phpBB/includes/functions_profile_fields.php
@@ -490,7 +490,8 @@ class custom_profile
else if ($day && $month && $year)
{
global $user;
- return $user->format_date(mktime(0, 0, 0, $month, $day, $year), $user->lang['DATE_FORMAT'], true);
+ // d/m/y 00:00 GMT isn't necessarily on the same d/m/y in the user's timezone, so add the timezone seconds
+ return $user->format_date(gmmktime(0, 0, 0, $month, $day, $year) + $user->timezone + $user->dst, $user->lang['DATE_FORMAT'], true);
}
return $value;