Loolooii
Loolooii

Reputation: 9190

Dutch localization (date, etc.) in CakePHP?

I have already used setLocale(LC_TIME, "nl_NL") and setLocale(LC_ALL, "nl_NL") in bootstap.php file and none of them seem to work. Please note that I don't want to translate anything(this is what I came across a lot when searching for this), because the website will be completely in Dutch. I just want localization, including for example names of months and other stuff. Is there a simple way to do this?

Upvotes: 0

Views: 497

Answers (1)

ADmad
ADmad

Reputation: 8100

Did you check the return value of setlocale()? It will work only if the locale you are trying to set is actually available on your server. Use locale -a in terminal to check available locales. Also check CakePHP manual for how localization is done in Cake. You can use the TimeHelper and NumberHelper for localized time and currency. The TimeHelper needs the LC_TIME file for your locale.

Upvotes: 2

Related Questions