#a way to change Localization in Laravel 9 without session()->put('locale', $locale); ?

7 messages · Page 1 of 1 (latest)

rich oasis
#

Change the app.locale configuration value.

warped valley
#

you mean if (! in_array($locale, ['en', 'es', 'fr'])) {
abort(400);
}

#

and then i want to change it without session

rich oasis
#

What?

#

You need to provide more detail.

#

Where are you trying to change the locale and how?

warped valley
#

i have no code. I look at others code implementation on the web ,but mostly what i found is when they use the session()->put('locale', $locale);