RTC bug PR-5.4-dev Pending

User tests: Successful: Unsuccessful:

avatar krishnagandhicode
krishnagandhicode
20 Mar 2026

Pull Request resolves #29134

  • I read the Generative AI policy and my contribution is either not created with the help of AI or is compatible with the policy and GNU/GPL 2 or later.

Summary of Changes

This PR fixes an issue where the Media Manager applies the user's timezone offset 2 times which results in incorrect "Date Created" and "Date Modified" times

In the local filesystem adapter, create_date_formatted and modified_date_formatted were generated using HTMLHelpr even though the date objects had already been adjusted to the configured timezone.
That caused the timezone conversion to be applied again in formatting, which produced shifted times confusion

The fix now formats the existing Date objects directly:
-create_date_formatted uses $createDate->format(Text::_('DATE_FORMAT_LC5'), true) and similarly for modified_date_formatted.

Testing Instructions

Go to System -> global Config -> under Server look for Location.
Change your Website Time Zone from UTC to a timezone with a some offset like for Asia/Kolkata (UTC+5:30), to make the bug visible.
image

now go to content -> media Upload an image and make sure to note your actual time.
now click on that i(info) button in top right and then click on the image you just uploaded - you get the details.

Actual result BEFORE applying this Pull Request

The "Date Created" time is shifted 2 times by the timezone offset . (e.g. as in my shared case if you set the timezone to UTC+5:30 now the timestamp will display exactly 11 hours ahead of UTC time instead of 5.5 hours).

image

In this SS as you can see that in my Windows Clock(bottom right) it UTC +5:30 : 16:30
and Joomla took the 11:00 UTC time, added the +5:30 offset once, and then added the +5:30 offset a second time, resulting in exactly 22:00)
as you see in the created Date : 22:00
I deliberately uploaded the file at exactly 16:30 IST(11:00 UTC, Kolkata) to make the math easy/clear : )

Expected result AFTER applying this Pull Request

The "Date Created" time reflects the time in whatever timezone is currently set in the Global Configuration - without any extra offsets

For my shared example: now it shows 16:30 (beacuse I uploaded it at 16:30 IST)
image

You can also test by uploading new images..

Link to documentations

Please select:

  • Documentation link for guide.joomla.org:

  • No documentation changes for guide.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

Votes

# of Users Experiencing Issue
1/1
Average Importance Score
5.00

avatar krishnagandhicode krishnagandhicode - open - 20 Mar 2026
avatar krishnagandhicode krishnagandhicode - change - 20 Mar 2026
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 20 Mar 2026
Category Front End Plugins
avatar krishnagandhicode krishnagandhicode - change - 20 Mar 2026
Labels Added: PR-5.4-dev
avatar brianteeman
brianteeman - comment - 20 Mar 2026

great spot!!

avatar krishnagandhicode krishnagandhicode - change - 20 Mar 2026
The description was changed
avatar krishnagandhicode krishnagandhicode - edited - 20 Mar 2026
avatar exlemor exlemor - test_item - 20 Mar 2026 - Tested successfully
avatar exlemor
exlemor - comment - 20 Mar 2026

I have tested this item ✅ successfully on 0cde490

I was able to successfully test this! :) Thanks and great find @krishnagandhicode!


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/47433.

avatar tecpromotion tecpromotion - test_item - 20 Mar 2026 - Tested successfully
avatar tecpromotion
tecpromotion - comment - 20 Mar 2026

I have tested this item ✅ successfully on 0cde490

Very nice catch! Thanks!


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/47433.

avatar tecpromotion tecpromotion - change - 20 Mar 2026
Status Pending Ready to Commit
avatar tecpromotion
tecpromotion - comment - 20 Mar 2026

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/47433.

avatar muhme muhme - change - 1 Apr 2026
Labels Added: RTC bug
avatar muhme
muhme - comment - 1 Apr 2026

✅ Final test before merge with JBT

  • Set Website Time Zone to Berlin (actual +2h), seen the error before
  • Applied PR with Patch Tester, date & time are correct now
avatar muhme muhme - change - 1 Apr 2026
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2026-04-01 09:32:02
Closed_By muhme
avatar muhme muhme - close - 1 Apr 2026
avatar muhme muhme - merge - 1 Apr 2026
avatar muhme
muhme - comment - 1 Apr 2026

Thank you @krishnagandhicode for your contribution. Thank you @exlemor and @tecpromotion for testing.

avatar krishnagandhicode
krishnagandhicode - comment - 1 Apr 2026

Thanks for the merge, and thanks to everyone who helped with Testing.

Add a Comment

Login with GitHub to post a comment