ZenphotoCMS 1.6.3

elFinderPluginSanitizer extends elFinderPlugin
in package

elFinder Plugin Sanitizer Sanitizer of file-name and file-path etc.

ex. binding, configure on connector options $opts = array( 'bind' => array( 'upload.pre mkdir.pre mkfile.pre rename.pre archive.pre ls.pre' => array( 'Plugin.Sanitizer.cmdPreprocess' ), 'upload.presave paste.copyfrom' => array( 'Plugin.Sanitizer.onUpLoadPreSave' ) ), // global configure (optional) 'plugin' => array( 'Sanitizer' => array( 'enable' => true, 'targets' => array('\','/',':','','?','"','<','>','|'), // target chars 'replace' => '_', // replace to this 'callBack' => null // Or @callable sanitize function ) ), // each volume configure (optional) 'roots' => array( array( 'driver' => 'LocalFileSystem', 'path' => '/path/to/files/', 'URL' => 'http://localhost/to/files/' 'plugin' => array( 'Sanitizer' => array( 'enable' => true, 'targets' => array('\','/',':','','?','"','<','>','|'), // target chars 'replace' => '_', // replace to this 'callBack' => null // Or @callable sanitize function ) ) ) ) );

Tags
author

Naoki Sawada

license

New BSD

Table of Contents

Properties

$opts  : array<string|int, mixed>
This plugin's options
$keyMap  : mixed
$replaced  : mixed

Methods

__construct()  : mixed
cmdPostprocess()  : mixed
cmdPreprocess()  : mixed
onUpLoadPreSave()  : mixed
getCurrentOpts()  : array<string|int, mixed>
Get current volume's options
iaEnabled()  : bool
Is enabled with options
sanitizeFileName()  : mixed

Properties

$opts

This plugin's options

protected array<string|int, mixed> $opts = array()

$keyMap

private mixed $keyMap = array('ls' => 'intersect', 'upload' => 'renames', 'mkdir' => array('name', 'dirs'))

$replaced

private mixed $replaced = array()

Methods

__construct()

public __construct(mixed $opts) : mixed
Parameters
$opts : mixed

cmdPostprocess()

public cmdPostprocess(mixed $cmd, mixed &$result, mixed $args, mixed $elfinder, mixed $volume) : mixed
Parameters
$cmd : mixed
$result : mixed
$args : mixed
$elfinder : mixed
$volume : mixed

cmdPreprocess()

public cmdPreprocess(mixed $cmd, mixed &$args, mixed $elfinder, mixed $volume) : mixed
Parameters
$cmd : mixed
$args : mixed
$elfinder : mixed
$volume : mixed

onUpLoadPreSave()

public onUpLoadPreSave(mixed &$thash, mixed &$name, mixed $src, mixed $elfinder, mixed $volume) : mixed
Parameters
$thash : mixed
$name : mixed
$src : mixed
$elfinder : mixed
$volume : mixed

getCurrentOpts()

Get current volume's options

protected getCurrentOpts(object $volume) : array<string|int, mixed>
Parameters
$volume : object
Return values
array<string|int, mixed>

options

iaEnabled()

Is enabled with options

protected iaEnabled(array<string|int, mixed> $opts[, elFinder $elfinder = null ]) : bool
Parameters
$opts : array<string|int, mixed>
$elfinder : elFinder = null
Return values
bool

sanitizeFileName()

protected sanitizeFileName(mixed $filename, mixed $opts) : mixed
Parameters
$filename : mixed
$opts : mixed

        
On this page

Search results