I can’t ever remember changing the format. Just as a test I created a test user and logged into usermin and dates fine its using the aussie format for date. Not sure why you system would be different, maybe someone on @staff might know.
Thanks Ilia, Usermin and Webmin are already set that way, but still it displays as MM/DD/YY
The only fix I have found is per user, Login to webmail /Usermin / Usermin / Change Language / set Locale to Manual, then select English (Australia).
Messy for sure.
Per Domain in Virtualmin, Administration Options / Switch to Server’s Admin / Virtual Server Details / Webmin Modules / Change Language and Theme / set Locale to Manual and then select English (Australia)
Still messy, but then also works for new users in that domain. Previously created users don’t appear to be affected, but I have done so many tests I am getting a bit confuddled!
Eitherway, if Usermin could just read the Locale from the server OS - which it may be doing on eg Centos 7 that Stefan uses, it would save a lot of messing about for me, and probably other people if it is an RHEL9 issue.
Agreed, ideally we need to centralize that. And I already tried to do that by putting this all under single Change Language and Theme page to control for a user and to Webmin (Usermin) Configuration: Language and Locale page to set it globally for all users. This isn’t that bad.
But I almost completely forgotten that mail has its own date format options for some reason … Probably @Jamie could explain the reason behind it better, and/or remove those completely to rely only on whatever is defined on Webmin side (or Usermin side).
Could it be that I need to make a change at the OS level?
Not sure what you mean exactly … but the main obstacle is that we have two separate date formats (technically).
The old one is when the date generated on the server side, in the server executed scripts, which never reach/output to UI. In this case, it’s controlled by Server generated date format option in Locale configuration / Manual … the old location for this date control feature was Webmin (Usermin) Configuration: User Interface page, i.e. raw dateformat option. This old feature is not very flexible in providing locale based formatted date/time.
The new one, that happens on the theme side, which only receives the timestamp from the server, and process it in UI according to finesse user preferences. It’s much more flexible and powerful.
The best solution would be is to pre-process date/time solely on the server side. But that would require a lot of work (on Perl side) to support different formats and locales. This is not trivial. Actually, it’s like a separate project on its own.
I would personally loved to remove all extra code, and solely rely on localectl output and build human readable dates/time on the server side.
As writing this, and looking at the code I remembered that we already do/have something familiar to this (i.e. respect/pass browser defined language/locale to process dates/time). There is an option called acceptlang which is controlled in UI on Webmin ⇾ Webmin Configuration: Language and Locale page with Use language specified by browser? option. So, if you set it to Yes and your browser language is set to English (Australia) (or whatever) then the whole UI will use that language and display dates accordingly too.
I wouldn’t mind dropping completely date/time processing on UI side and use DateTime::Locale instead. @Jamie, it would require rework on Webmin side – how do you feel about that?