Welcome Guest, Not a member yet? Register   Sign In
setLocale() doesn't change the language set by browser
#3

(This post was last modified: 04-26-2020, 10:50 AM by thingNumber1.)

To set the language you need to do this:

PHP Code:
$language = \Config\Services::language();
$language->setLocale($real_language); 

That way you won't need to set the language every single time. Also, I think that this function would do the validation for you.
Reply


Messages In This Thread
RE: setLocale() doesn't change the language set by browser - by thingNumber1 - 04-26-2020, 10:48 AM



Theme © iAndrew 2016 - Forum software by © MyBB