Laravel 5.0.* middleware to remove prefix locale from url before routes are processed
问题 I am looking for a way to make all app route's have multiple locales without using route groups. This is because I use an external extensions package, which means routes are registered in many places. Essentially I want to have /foo/bar as well as /en/foo/bar, /de/foor/bar, /es/foo/bar etc all to be recognised and processed by the /foot/bar route Route::get('foo/bar', function () { return App::getLocale() . ' result'; }); So the above would give me 'en result' or 'de result' or 'es result'. I