How to install a “locale” to be used in php on a o

2019-07-07 01:12发布

问题:

I'm developing a website that needs multilingual support. I am trying to use locales in php but a certain locale (es-CO) is not available in my development machine. It is on my hosting server. I've researched on how to add new locales but can't find how or where to get the new locale files. Should this be installed in the OS, on apache or on php? and where can I get these files? in linux i've found that running sudo-apt get language-pack-es-base does this but no idea how to do this in osx. Knowing how to do it in windows should come in handy also.

Thanks!

回答1:

As @alombarte said here Just type in Terminal

cd /usr/share/locale
sudo cp -R es_ES es_CO

check by executing locale -a OR

locale -a | grep es_


回答2:

If i'm correct you can install more locales using the Max OS X install disk