Skip to content
Discussion options

You must be logged in to vote

Hi!
In order to control what gets done or not in file manager, you must use a middleware.

  1. Go to config\elfinder.php, and add the accessControl key to your disk.
    Note that you can have multiple disks with different access control.
'disks' => [
    'mydisk' => [
        'alias' => 'Storage',
        'accessControl' => 'App\Http\Middleware\ElfinderAccess::checkAccess',
        'visibility' => 'public',
    ],
],
  1. Create your app\Http\MiddlewareElfinderAccess.php middelware.
<?php
namespace App\Http\Middleware;

class ElfinderAccess
{
    public static function checkAccess($attr, $path, $data, $volume)
    {
        if (...) { // your rules
            return false;
        }

        return 

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by pxpm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants