PHP code example of birdsolutions / laravel-language
1. Go to this page and download the library: Download birdsolutions/laravel-language library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
birdsolutions / laravel-language example snippets
$xslt
[
/*
* Package Service Providers...
*/
BirdSolutions\Language\Providers\LanguageServiceProvider::class,
]
php artisan vendor:publish --provider="BirdSolutions\Language\Providers\LanguageServiceProvider"
$xslt
Route::group([
'prefix' => \Language::getLocale(),
'middleware' => 'language'
], function () {
// Add Localized routes here.
});
$xslt
<a href='/language?language=en'>English</a>