PHP code example of brainstorm / slim4locale
1. Go to this page and download the library: Download brainstorm/slim4locale 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/ */
brainstorm / slim4locale example snippets
use BrainStorm\Slim4Locale\Locale;
$enabled = true; //or false if disabled
$languages = ['en', 'de', 'it']; //all the languages permitted
$app->add(new Locale($app, $enabled, $languages));
$request->getAttribute('locale');