22 lines
337 B
PHP
22 lines
337 B
PHP
|
<?php
|
||
|
|
||
|
namespace App\Http\Controllers;
|
||
|
|
||
|
use Illuminate\Http\Request;
|
||
|
use Illuminate\Support\Facades\App;
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
class LangController extends Controller
|
||
|
{
|
||
|
public function change(Request $request)
|
||
|
{
|
||
|
App::setlocale($request->lang);
|
||
|
session()->put('locale', $request->lang);
|
||
|
return redirect()->back();
|
||
|
}
|
||
|
}
|