Quantcast
Channel: Joomla! Forum - community, help and support
Viewing all articles
Browse latest Browse all 632

General Questions/New to Joomla! 3.x • Changed directly in MySQL publish_up field for a module shows VERY wrong time

$
0
0
Hello to Community !
I hope many of us agree that Joomla 3.9 still works very well and sometimes not so easy to upgrade because requires serious migration - due to that I'm still at J 3.9.
I've met a problem what is extremely strange for my understanding.
Environment - Almalinux 9, Joomla 3.9, PHP 7.4.33, Apache, MySQL 8.0
PROBLEM DESCRIPTION
1) As always - check Joomla site settings Website Zone - "America/Chicago"
2) Create Joomla article and check using native Joomla PHP code inside article
$created_time = JFactory::getDate('now', 'America/Chicago')->toSql();
echo "$created_time";
= 2024-09-25 13:40:39
3) check PHP server time at the same article
echo '<b> PHP server time ' . date('Y-m-d H:i:s') . '</b><br>';
= 2024-09-25 13:40:39
4) check general server shell time
Wed Sep 25 01:40:47 PM CDT 2024
5) check MySQL time
mysql -uroot -e 'SELECT NOW()'
= 2024-09-25 13:40:58
SO - EVERYTHING POSSIBLE WAY shows the SAME current Chicago time EVERYWHERE (no mention seconds difference between the commands performed)
---------------------
Now let's set directly using server shell command
1) mysql -uroot -N -e 'UPDATE joomla.apncl_modules SET publish_up = NOW() WHERE id=238' ;
2) check result
mysql -uroot -e 'SELECT publish_up FROM joomla.apncl_modules WHERE id=238' ;
= 2024-09-25 13:41:12
3) FINALLY - open Module with id = 238 from Administrator backend interface and see "Start Publishing"
!!!??? = 2024-09-25 08:41:32

WHY Administrator backend interface shows (and use) completely WRONG datetime ?
No joking - why Module Admin interface do not use direct correct datetime from according MySQL field ?
Is it possible somewhere to fix this abnormal "time playing", may be directly changing a code or setting inside Joomla PHP files ?
I suppose it could be inside /libraries/src/Date/Date.php - but can't catch what and how to change.

Would be very obliged to Community for any idea to try,
Regards,
Serge

Statistics: Posted by Sarge_2022 — Wed Sep 25, 2024 7:20 pm



Viewing all articles
Browse latest Browse all 632

Trending Articles