I am planning to use strftime()
, however when I check my server regarding what's available locale, via (locale -a)
, I only have this:
C
en_US.utf8
POSIX
I badly need to have this de_DE.utf8, in order to turn my dates to German. How can I add additional locale? Is there any other better way?
If you want to change or set system local, use the update-locale program. The LANG variable allows you to set the locale for the entire system. The following command sets LANG to en_IN. UTF-8 and removes definitions for LANGUAGE.
One solution to fix this issue, first run the locale command to list the locales currently defined for your user account. To generate the missing locale and reconfigure locales, identify the name of your locale ( in my case de_DE. UTF-8 ), or use one another one that you prefer, such as en_US. UTF-8 .
dpkg-reconfigure locales does nothing for me on a plain vanilla install of Ubuntu 12.04 LTS, but locale-gen works like a charm:
sudo locale-gen de_DE.utf8
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With