Here is my code in config.php:
$path = '/laravel/';
require _DIR_.'/../../../../bootstrap/autoload.php';
$app = require_once _DIR_.'/../../../../bootstrap/app.php';
$app->make('Illuminate\Contracts\Http\Kernel')->handle(Illuminate\Http\Request::capture());
$_user = (Auth::check()) ? Auth::user()->username : '';
define('CKFINDER_ROOT_FOLDER', $path.'resources/assets/uploads/' . $_user .'/');
$config['authentication'] = function () {
return Auth::check();
};
It works well but I can't upload file (Upload finished with errors). If I remove ->handle(Illuminate\Http\Request::capture() for test, it would run perfectly in this session (not refresh page). Where is my problem. Please help.