Advertisement
Guest User

Untitled

a guest
Jul 26th, 2016
55
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.42 KB | None | 0 0
  1. $opts = array(
  2. 'debug' => true,
  3. 'roots' => array(
  4. array(
  5. 'driver' => 'LocalFileSystem', // driver for accessing file system (REQUIRED)
  6. 'path' => '../files/', // path to files (REQUIRED)
  7. 'URL' => dirname($_SERVER['PHP_SELF']) . '/../files/', // URL to files (REQUIRED)
  8. 'uploadDeny' => array('all'), // All Mimetypes not allowed to upload
  9. 'uploadAllow' => array('image', 'text/plain'),// Mimetype `image` and `text/plain` allowed to upload
  10. 'uploadOrder' => array('deny', 'allow'), // allowed Mimetype `image` and `text/plain` only
  11. 'accessControl' => 'access', // disable and hide dot starting files (OPTIONAL)
  12. 'attributes' => array(
  13. array(
  14. 'pattern' => '/^.IT/LockedFolder/', //You can also set permissions for file types by adding, for example, .jpg inside pattern.
  15. 'read' => true,
  16. 'write' => false,
  17. 'locked' => true,
  18. )
  19. )
  20. )
  21. )
  22. );
  23.  
  24. // run elFinder
  25. $connector = new elFinderConnector(new elFinder($opts));
  26. $connector->run();
  27.  
  28. 'pattern' => '/^.IT/',
  29.  
  30. user_id | folder_name | read | write | locked
  31. 1 | IT | true | false | true
  32. 2 | IT/LockedFolder | false | false | false
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement