PHP code example of johnnestebann / langravel
1. Go to this page and download the library: Download johnnestebann/langravel 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/ */
johnnestebann / langravel example snippets
php artisan vendor:publish --provider="Johnnestebann\Langravel\ServiceProvider" --tag=route
php artisan vendor:publish --provider="Johnnestebann\Langravel\ServiceProvider" --tag=config
'supportedLocales' => ['hr', 'en'],
'defaultLocale' => 'en',
foreach (config('langravel.supportedLocales') as $locale) {
URL::overrideParameters($locale, $model->{'slug_'.$locale});
}