We constructed ours using a before middleware. Checked, in order, are a lang= query param, a session var, then finally a user's preference (stored in the DB). If any are set we check (via \Waavi\Translation\Repositories\LanguageRepository) that it's a valid locale before simply calling:
We constructed ours using a before middleware. Checked, in order, are a
lang=
query param, a session var, then finally a user's preference (stored in the DB). If any are set we check (via\Waavi\Translation\Repositories\LanguageRepository
) that it's a valid locale before simply calling: