Set twig globals on 404 pages. Fixes #2198
Merge pull request #2219 from GDmac/master

set locale UTF-8
Strict match for config::getwhichend()