mirror of
https://github.com/scummvm/scummvm-web.git
synced 2026-06-20 05:45:49 +00:00
As mentioned in f3c2203e2f,
the language switching was always 1 behind. As in, the
language would be the last language you selected.
The first problem is that some of the smarty config variables
were being set after the call to _smarty->config_load(). Since
the smarty instance is cached, it was using the last set of variables.
I don't know why the production web site isn't throwing errors. My
personal set up wouldn't load until I could set _smarty->compile_dir
the first time. Perhaps the language update was done on the fly, so
smarty was still cached.
The next potential problem is persistence with $_SESSION.
The session is never initialized with session_start(). However,
the production php.ini may have session auto start enabled.