diff options
Diffstat (limited to 'phpBB/includes/functions_profile_fields.php')
-rw-r--r-- | phpBB/includes/functions_profile_fields.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/phpBB/includes/functions_profile_fields.php b/phpBB/includes/functions_profile_fields.php index 47d3ae03a9..7c5e39c3a7 100644 --- a/phpBB/includes/functions_profile_fields.php +++ b/phpBB/includes/functions_profile_fields.php @@ -469,8 +469,8 @@ class custom_profile // case 'datetime': case 'date': $date = explode('-', $value); - $month = (isset($date[0])) ? (int) $date[0] : 0; - $day = (isset($date[1])) ? (int) $date[1] : 0; + $day = (isset($date[0])) ? (int) $date[0] : 0; + $month = (isset($date[1])) ? (int) $date[1] : 0; $year = (isset($date[2])) ? (int) $date[2] : 0; if (!$day && !$month && !$year) @@ -479,7 +479,8 @@ class custom_profile } else if ($day && $month && $year) { - return sprintf('%4d-%02d-%02d', $year, $month, $day); + global $user; + return $user->format_date(mktime(0, 0, 0, $month, $day, $year), $user->lang['DATE_FORMAT'], true); } return $value; |