Description
I am trying to understand some user profile code in emoncms and noticed that the default locale code seems to be "en_EN" is that intended/correct?
It doesn't seem to be a standard locale code, should we not be using "en-GB" as the default?
(I'm new to JS and not great with PHP so apologies if I ask a stupid question)
Whilst looking at using a user account timezone in client run javascript I found the JS toLocaleString() function uses a locale to format the date and time string eg
var acct_time = new Date().toLocaleString("en-GB", {timeZone: "Australia/Sydney", timeZoneName: "long"})
document.getElementById('acct_time').innerHTML = acct_time;
so I was just pondering on whether the session['lang'] would be suitable/available to use (in addition to adding a new session['timezone'] variable) and found this code which threw me a bit.
https://github.com/emoncms/emoncms/blob/9.8.30/locale.php#L62-L93
This won't effect using a user account (session?) timezone directly, but I was thinking that displaying the current time in both session and browser timezones might be useful to the viewer.