you can use
https:
Laravel localization uses the URL provided for the request. To achieve this, a group must be added to the routes.php file. It will filter all pages that should be localized.
// app/routes.php Route::group(array('prefix' => LaravelLocalization::setLanguage()), function() { /** ADD ALL LOCALIZED ROUTES INSIDE THIS GROUP **/ Route::get('/', function() { return View::make('hello'); }); Route::get('test',function(){ return View::make('test'); }); }); /** OTHER PAGES THAT SHOULD NOT BE LOCALIZED **/
After adding this group to the route file, the user can access all languages added to "languagesAllowed" ("en" and "es" by default, see the configuration section to change this parameter). For example, a user can now access two different languages using the following addresses:
http://laravel.com/en
http://laravel.com/es
http://laravel.com
Sangar82
source share