Completed
Push — 2.x ( eff17c...66a3e5 )
by Naoki
02:58
created
php/elFinder.class.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1344,7 +1344,7 @@
 block discarded – undo
1344 1344
 	 * 
1345 1345
 	 * @param  string $str
1346 1346
 	 * @param  array  $extTable
1347
-	 * @return array
1347
+	 * @return string[]
1348 1348
 	 * @author Naoki Sawada
1349 1349
 	 */
1350 1350
 	protected function parse_data_scheme( $str, $extTable ) {
Please login to merge, or discard this patch.
Indentation   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -1149,18 +1149,18 @@  discard block
 block discarded – undo
1149 1149
 	}
1150 1150
 
1151 1151
 	/**
1152
-	* Get remote contents
1153
-	*
1154
-	* @param  string   $url     target url
1155
-	* @param  int      $timeout timeout (sec)
1156
-	* @param  int      $redirect_max redirect max count
1157
-	* @param  string   $ua
1158
-	* @param  resource $fp
1159
-	* @return string or bool(false)
1160
-	* @retval string contents
1161
-	* @retval false  error
1162
-	* @author Naoki Sawada
1163
-	**/
1152
+	 * Get remote contents
1153
+	 *
1154
+	 * @param  string   $url     target url
1155
+	 * @param  int      $timeout timeout (sec)
1156
+	 * @param  int      $redirect_max redirect max count
1157
+	 * @param  string   $ua
1158
+	 * @param  resource $fp
1159
+	 * @return string or bool(false)
1160
+	 * @retval string contents
1161
+	 * @retval false  error
1162
+	 * @author Naoki Sawada
1163
+	 **/
1164 1164
 	protected function get_remote_contents( &$url, $timeout = 30, $redirect_max = 5, $ua = 'Mozilla/5.0', $fp = null ) {
1165 1165
 		$method = (function_exists('curl_exec') && !ini_get('safe_mode'))? 'curl_get_contents' : 'fsock_get_contents'; 
1166 1166
 		return $this->$method( $url, $timeout, $redirect_max, $ua, $fp );
@@ -2090,12 +2090,12 @@  discard block
 block discarded – undo
2090 2090
 	}
2091 2091
 	
2092 2092
 	/**
2093
-	* Return content URL
2094
-	*
2095
-	* @param  array  $args  command arguments
2096
-	* @return array
2097
-	* @author Naoki Sawada
2098
-	**/
2093
+	 * Return content URL
2094
+	 *
2095
+	 * @param  array  $args  command arguments
2096
+	 * @return array
2097
+	 * @author Naoki Sawada
2098
+	 **/
2099 2099
 	protected function url($args) {
2100 2100
 		$target = $args['target'];
2101 2101
 		$options = isset($args['options'])? $args['options'] : array();
Please login to merge, or discard this patch.
php/elFinderVolumeDriver.class.php 2 patches
Doc Comments   +17 added lines, -21 removed lines patch added patch discarded remove patch
@@ -1176,7 +1176,6 @@  discard block
 block discarded – undo
1176 1176
 	 * Return file info or false on error
1177 1177
 	 *
1178 1178
 	 * @param  string   $hash      file hash
1179
-	 * @param  bool     $realpath  add realpath field to file info
1180 1179
 	 * @return array|false
1181 1180
 	 * @author Dmitry (dio) Levashov
1182 1181
 	 **/
@@ -1197,7 +1196,6 @@  discard block
 block discarded – undo
1197 1196
 	 * Return folder info
1198 1197
 	 *
1199 1198
 	 * @param  string   $hash  folder hash
1200
-	 * @param  bool     $hidden  return hidden file info
1201 1199
 	 * @return array|false
1202 1200
 	 * @author Dmitry (dio) Levashov
1203 1201
 	 **/
@@ -1530,7 +1528,6 @@  discard block
 block discarded – undo
1530 1528
 	 *
1531 1529
 	 * @param  Resource $fp      file pointer
1532 1530
 	 * @param  string   $dst     destination folder hash
1533
-	 * @param  string   $src     file name
1534 1531
 	 * @param  string   $tmpname file tmp name - required to detect mime type
1535 1532
 	 * @return array|false
1536 1533
 	 * @author Dmitry (dio) Levashov
@@ -1616,7 +1613,6 @@  discard block
 block discarded – undo
1616 1613
 	 * Paste files
1617 1614
 	 *
1618 1615
 	 * @param  Object  $volume  source volume
1619
-	 * @param  string  $source  file hash
1620 1616
 	 * @param  string  $dst     destination dir hash
1621 1617
 	 * @param  bool    $rmSrc   remove source after copy?
1622 1618
 	 * @return array|false
@@ -2235,7 +2231,6 @@  discard block
 block discarded – undo
2235 2231
 	 * Open file and return file pointer (with convert encording)
2236 2232
 	 *
2237 2233
 	 * @param  string  $path  file path
2238
-	 * @param  bool    $write open file for writing
2239 2234
 	 * @return resource|false
2240 2235
 	 * @author Naoki Sawada
2241 2236
 	 **/
@@ -2366,7 +2361,8 @@  discard block
 block discarded – undo
2366 2361
 	 * Not implemented
2367 2362
 	 *
2368 2363
 	 * @param  string  path
2369
-	 * @return mixed
2364
+	 * @param string $path
2365
+	 * @return string
2370 2366
 	 * @author Dmitry (dio) Levashov
2371 2367
 	 **/
2372 2368
 	protected function crypt($path) {
@@ -2378,7 +2374,8 @@  discard block
 block discarded – undo
2378 2374
 	 * Not implemented
2379 2375
 	 *
2380 2376
 	 * @param  mixed  hash
2381
-	 * @return mixed
2377
+	 * @param string $hash
2378
+	 * @return string
2382 2379
 	 * @author Dmitry (dio) Levashov
2383 2380
 	 **/
2384 2381
 	protected function uncrypt($hash) {
@@ -2408,7 +2405,6 @@  discard block
 block discarded – undo
2408 2405
 	/**
2409 2406
 	 * Return new unique name based on file name and suffix
2410 2407
 	 *
2411
-	 * @param  string  $path    file path
2412 2408
 	 * @param  string  $suffix  suffix append to name
2413 2409
 	 * @return string
2414 2410
 	 * @author Dmitry (dio) Levashov
@@ -2476,6 +2472,7 @@  discard block
 block discarded – undo
2476 2472
 	 * @param  string $to      to character encoding
2477 2473
 	 * @param  string $locale  local locale
2478 2474
 	 * @param  string $unknown replaces character for unknown
2475
+	 * @param boolean $restoreLocale
2479 2476
 	 * @return mixed
2480 2477
 	 */
2481 2478
 	protected function convEnc($var, $from, $to, $locale, $restoreLocale, $unknown = '_') {
@@ -2657,6 +2654,7 @@  discard block
 block discarded – undo
2657 2654
 	 *
2658 2655
 	 * @param string $dir  parent dir path
2659 2656
 	 * @param string $name new file name
2657
+	 * @param boolean $isDir
2660 2658
 	 * @return bool
2661 2659
 	 * @author Dmitry (dio) Levashov
2662 2660
 	 **/
@@ -3186,7 +3184,7 @@  discard block
 block discarded – undo
3186 3184
 	 * @param  string  $src   source path
3187 3185
 	 * @param  string  $dst   destination dir path
3188 3186
 	 * @param  string  $name  new file name (optionaly)
3189
-	 * @return string|false
3187
+	 * @return boolean|string
3190 3188
 	 * @author Dmitry (dio) Levashov
3191 3189
 	 **/
3192 3190
 	protected function copy($src, $dst, $name) {
@@ -3239,7 +3237,7 @@  discard block
 block discarded – undo
3239 3237
 	 * @param  string  $src   source path
3240 3238
 	 * @param  string  $dst   destination dir path
3241 3239
 	 * @param  string  $name  new file name 
3242
-	 * @return string|false
3240
+	 * @return string|boolean
3243 3241
 	 * @author Dmitry (dio) Levashov
3244 3242
 	 **/
3245 3243
 	protected function move($src, $dst, $name) {
@@ -3265,7 +3263,7 @@  discard block
 block discarded – undo
3265 3263
 	 * @param  string  $src          source file hash
3266 3264
 	 * @param  string  $destination  destination dir path
3267 3265
 	 * @param  string  $name         file name
3268
-	 * @return string|false
3266
+	 * @return boolean|string
3269 3267
 	 * @author Dmitry (dio) Levashov
3270 3268
 	 **/
3271 3269
 	protected function copyFrom($volume, $src, $destination, $name) {
@@ -3409,7 +3407,7 @@  discard block
 block discarded – undo
3409 3407
 	 * @param  string  $path  thumnbnail path 
3410 3408
 	 * @param  array   $stat  file stat
3411 3409
 	 * @param  bool    $checkTmbPath
3412
-	 * @return string|bool
3410
+	 * @return boolean
3413 3411
 	 * @author Dmitry (dio) Levashov
3414 3412
 	 **/
3415 3413
 	protected function canCreateTmb($path, $stat, $checkTmbPath = true) {
@@ -3426,7 +3424,7 @@  discard block
 block discarded – undo
3426 3424
 	 *
3427 3425
 	 * @param  string  $path  thumnbnail path 
3428 3426
 	 * @param  array   $stat  file stat
3429
-	 * @return string|bool
3427
+	 * @return boolean
3430 3428
 	 * @author Dmitry (dio) Levashov
3431 3429
 	 **/
3432 3430
 	protected function canResize($path, $stat) {
@@ -3437,7 +3435,6 @@  discard block
 block discarded – undo
3437 3435
 	 * Create thumnbnail and return it's URL on success
3438 3436
 	 *
3439 3437
 	 * @param  string  $path  file path
3440
-	 * @param  string  $mime  file mime type
3441 3438
 	 * @return string|false
3442 3439
 	 * @author Dmitry (dio) Levashov
3443 3440
 	 **/
@@ -3897,7 +3894,7 @@  discard block
 block discarded – undo
3897 3894
 	 *
3898 3895
 	 * @param  string  $command       command line
3899 3896
 	 * @param  array   $output        stdout strings
3900
-	 * @param  array   $return_var    process exit code
3897
+	 * @param  integer   $return_var    process exit code
3901 3898
 	 * @param  array   $error_output  stderr strings
3902 3899
 	 * @return int     exit code
3903 3900
 	 * @author Alexey Sukhotin
@@ -4048,7 +4045,7 @@  discard block
 block discarded – undo
4048 4045
 	* @param  string  $haystack  The string being checked.
4049 4046
 	* @param  string  $needle    The string to find in haystack.
4050 4047
 	* @param  int     $offset    The search offset. If it is not specified, 0 is used.
4051
-	* @return int|bool
4048
+	* @return integer
4052 4049
 	* @author Alexey Sukhotin
4053 4050
 	**/
4054 4051
 	protected function stripos($haystack , $needle , $offset = 0) {
@@ -4273,7 +4270,7 @@  discard block
 block discarded – undo
4273 4270
 	 * @param  array   $files  files names list
4274 4271
 	 * @param  string  $name   archive name
4275 4272
 	 * @param  array   $arc    archiver options
4276
-	 * @return string|bool
4273
+	 * @return string|false
4277 4274
 	 * @author Dmitry (dio) Levashov, 
4278 4275
 	 * @author Alexey Sukhotin
4279 4276
 	 * @author Naoki Sawada
@@ -4330,7 +4327,7 @@  discard block
 block discarded – undo
4330 4327
 	 * @param  string        $dir      target dir
4331 4328
 	 * @param  array         $files    files names list
4332 4329
 	 * @param  string|object $zipPath  Zip archive name
4333
-	 * @return void
4330
+	 * @return boolean
4334 4331
 	 * @author Naoki Sawada
4335 4332
 	 */
4336 4333
 	protected static function zipArchiveZip($dir, $files, $zipPath) {
@@ -4533,7 +4530,6 @@  discard block
 block discarded – undo
4533 4530
 	 * Open file and return file pointer
4534 4531
 	 *
4535 4532
 	 * @param  string  $path  file path
4536
-	 * @param  bool    $write open file for writing
4537 4533
 	 * @return resource|false
4538 4534
 	 * @author Dmitry (dio) Levashov
4539 4535
 	 **/
@@ -4586,7 +4582,7 @@  discard block
 block discarded – undo
4586 4582
 	 * Copy file into another file (only inside one volume)
4587 4583
 	 *
4588 4584
 	 * @param  string  $source  source file path
4589
-	 * @param  string  $target  target dir path
4585
+	 * @param  string  $targetDir  target dir path
4590 4586
 	 * @param  string  $name    file name
4591 4587
 	 * @return bool
4592 4588
 	 * @author Dmitry (dio) Levashov
@@ -4598,7 +4594,7 @@  discard block
 block discarded – undo
4598 4594
 	 * Return new file path or false.
4599 4595
 	 *
4600 4596
 	 * @param  string  $source  source file path
4601
-	 * @param  string  $target  target dir path
4597
+	 * @param  string  $targetDir  target dir path
4602 4598
 	 * @param  string  $name    file name
4603 4599
 	 * @return string|bool
4604 4600
 	 * @author Dmitry (dio) Levashov
Please login to merge, or discard this patch.
Indentation   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -1,16 +1,16 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Base class for elFinder volume.
4
- * Provide 2 layers:
5
- *  1. Public API (commands)
6
- *  2. abstract fs API
7
- *
8
- * All abstract methods begin with "_"
9
- *
10
- * @author Dmitry (dio) Levashov
11
- * @author Troex Nevelin
12
- * @author Alexey Sukhotin
13
- **/
3
+	 * Base class for elFinder volume.
4
+	 * Provide 2 layers:
5
+	 *  1. Public API (commands)
6
+	 *  2. abstract fs API
7
+	 *
8
+	 * All abstract methods begin with "_"
9
+	 *
10
+	 * @author Dmitry (dio) Levashov
11
+	 * @author Troex Nevelin
12
+	 * @author Alexey Sukhotin
13
+	 **/
14 14
 abstract class elFinderVolumeDriver {
15 15
 	
16 16
 	/**
@@ -192,11 +192,11 @@  discard block
 block discarded – undo
192 192
 		'mimefile'        => '',
193 193
 		// mime type normalize map : Array '[ext]:[detected mime type]' => '[normalized mime]'
194 194
 		'mimeMap'         => array(
195
-		                     'md:application/x-genesis-rom' => 'text/x-markdown',
196
-		                     'md:text/plain'                => 'text/x-markdown',
197
-		                     'markdown:text/plain'          => 'text/x-markdown',
198
-		                     'css:text/x-asm'               => 'text/css'
199
-		                    ),
195
+							 'md:application/x-genesis-rom' => 'text/x-markdown',
196
+							 'md:text/plain'                => 'text/x-markdown',
197
+							 'markdown:text/plain'          => 'text/x-markdown',
198
+							 'css:text/x-asm'               => 'text/css'
199
+							),
200 200
 		// directory for thumbnails
201 201
 		'tmbPath'         => '.tmb',
202 202
 		// mode to create thumbnails dir
@@ -4043,14 +4043,14 @@  discard block
 block discarded – undo
4043 4043
 	// }
4044 4044
 
4045 4045
 	/**
4046
-	* Find position of first occurrence of string in a string with multibyte support
4047
-	*
4048
-	* @param  string  $haystack  The string being checked.
4049
-	* @param  string  $needle    The string to find in haystack.
4050
-	* @param  int     $offset    The search offset. If it is not specified, 0 is used.
4051
-	* @return int|bool
4052
-	* @author Alexey Sukhotin
4053
-	**/
4046
+	 * Find position of first occurrence of string in a string with multibyte support
4047
+	 *
4048
+	 * @param  string  $haystack  The string being checked.
4049
+	 * @param  string  $needle    The string to find in haystack.
4050
+	 * @param  int     $offset    The search offset. If it is not specified, 0 is used.
4051
+	 * @return int|bool
4052
+	 * @author Alexey Sukhotin
4053
+	 **/
4054 4054
 	protected function stripos($haystack , $needle , $offset = 0) {
4055 4055
 		if (function_exists('mb_stripos')) {
4056 4056
 			return mb_stripos($haystack , $needle , $offset);
Please login to merge, or discard this patch.
php/elFinderVolumeDropbox.class.php 2 patches
Doc Comments   +5 added lines, -12 removed lines patch added patch discarded remove patch
@@ -234,7 +234,6 @@  discard block
 block discarded – undo
234 234
 	 * process of on netunmount
235 235
 	 * Drop table `dropbox` & rm thumbs
236 236
 	 * 
237
-	 * @param array $options
238 237
 	 * @return boolean
239 238
 	 */
240 239
 	public function netunmount($netVolumes, $key) {
@@ -431,7 +430,7 @@  discard block
 block discarded – undo
431 430
 	/**
432 431
 	 * Check DB for delta cache
433 432
 	 * 
434
-	 * @return void
433
+	 * @return boolean
435 434
 	 */
436 435
 	private function checkDB() {
437 436
 		$res = $this->query('SELECT * FROM sqlite_master WHERE type=\'table\' AND name=\''.$this->DB_TableName.'\'');
@@ -685,7 +684,7 @@  discard block
 block discarded – undo
685 684
 	* @param  string  $src   source path
686 685
 	* @param  string  $dst   destination dir path
687 686
 	* @param  string  $name  new file name (optionaly)
688
-	* @return string|false
687
+	* @return string|boolean
689 688
 	* @author Dmitry (dio) Levashov
690 689
 	* @author Naoki Sawada
691 690
 	**/
@@ -739,10 +738,6 @@  discard block
 block discarded – undo
739 738
 	* Create thumnbnail and return it's URL on success
740 739
 	*
741 740
 	* @param  string  $path  file path
742
-	* @param  string  $mime  file mime type
743
-	* @return string|false
744
-	* @author Dmitry (dio) Levashov
745
-	* @author Naoki Sawada
746 741
 	**/
747 742
 	protected function createTmb($path, $stat) {
748 743
 		if (!$stat || !$this->canCreateTmb($path, $stat)) {
@@ -1099,7 +1094,6 @@  discard block
 block discarded – undo
1099 1094
 	 * Open file and return file pointer
1100 1095
 	 *
1101 1096
 	 * @param  string  $path  file path
1102
-	 * @param  bool    $write open file for writing
1103 1097
 	 * @return resource|false
1104 1098
 	 * @author Dmitry (dio) Levashov
1105 1099
 	 **/
@@ -1141,7 +1135,7 @@  discard block
 block discarded – undo
1141 1135
 	 * Close opened file
1142 1136
 	 *
1143 1137
 	 * @param  resource  $fp  file pointer
1144
-	 * @return bool
1138
+	 * @return boolean|null
1145 1139
 	 * @author Dmitry (dio) Levashov
1146 1140
 	 **/
1147 1141
 	protected function _fclose($fp, $path='') {
@@ -1225,7 +1219,7 @@  discard block
 block discarded – undo
1225 1219
 	 * Return new file path or false.
1226 1220
 	 *
1227 1221
 	 * @param  string  $source  source file path
1228
-	 * @param  string  $target  target dir path
1222
+	 * @param  string  $targetDir  target dir path
1229 1223
 	 * @param  string  $name    file name
1230 1224
 	 * @return string|bool
1231 1225
 	 * @author Dmitry (dio) Levashov
@@ -1274,7 +1268,6 @@  discard block
 block discarded – undo
1274 1268
 	 * Return new file path or false on error.
1275 1269
 	 *
1276 1270
 	 * @param  resource  $fp   file pointer
1277
-	 * @param  string    $dir  target dir path
1278 1271
 	 * @param  string    $name file name
1279 1272
 	 * @param  array     $stat file stat (required by some virtual fs)
1280 1273
 	 * @return bool|string
@@ -1320,7 +1313,7 @@  discard block
 block discarded – undo
1320 1313
 	 *
1321 1314
 	 * @param  string  $path     file path
1322 1315
 	 * @param  string  $content  new file content
1323
-	 * @return bool
1316
+	 * @return boolean|string
1324 1317
 	 * @author Dmitry (dio) Levashov
1325 1318
 	 **/
1326 1319
 	protected function _filePutContents($path, $content) {
Please login to merge, or discard this patch.
Indentation   +49 added lines, -49 removed lines patch added patch discarded remove patch
@@ -192,7 +192,7 @@  discard block
 block discarded – undo
192 192
 						$options['url'] = $this->getConnectorUrl();
193 193
 					}
194 194
 					$callback  = $options['url']
195
-					           . '?cmd=netmount&protocol=dropbox&host=dropbox.com&user=init&pass=return&node='.$options['id'].$cdata;
195
+							   . '?cmd=netmount&protocol=dropbox&host=dropbox.com&user=init&pass=return&node='.$options['id'].$cdata;
196 196
 					
197 197
 					try {
198 198
 						$tokens = $this->oauth->getRequestToken();
@@ -265,9 +265,9 @@  discard block
 block discarded – undo
265 265
 	 */
266 266
 	private function getConnectorUrl() {
267 267
 		$url  = ((isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) !== 'off')? 'https://' : 'http://')
268
-		       . $_SERVER['SERVER_NAME']                                              // host
269
-		      . ($_SERVER['SERVER_PORT'] == 80 ? '' : ':' . $_SERVER['SERVER_PORT'])  // port
270
-		       . $_SERVER['REQUEST_URI'];                                             // path & query
268
+			   . $_SERVER['SERVER_NAME']                                              // host
269
+			  . ($_SERVER['SERVER_PORT'] == 80 ? '' : ':' . $_SERVER['SERVER_PORT'])  // port
270
+			   . $_SERVER['REQUEST_URI'];                                             // path & query
271 271
 		list($url) = explode('?', $url);
272 272
 		return $url;
273 273
 	}
@@ -605,7 +605,7 @@  discard block
 block discarded – undo
605 605
 		$stat['mime']  = $raw['is_dir']? 'directory' : $raw['mime_type'];
606 606
 		$stat['size']  = $stat['mime'] == 'directory' ? 0 : $raw['bytes'];
607 607
 		$stat['ts']    = isset($raw['client_mtime'])? strtotime($raw['client_mtime']) :
608
-		                (isset($raw['modified'])? strtotime($raw['modified']) : $_SERVER['REQUEST_TIME']);
608
+						(isset($raw['modified'])? strtotime($raw['modified']) : $_SERVER['REQUEST_TIME']);
609 609
 		$stat['dirs'] = 0;
610 610
 		if ($raw['is_dir']) {
611 611
 			$stat['dirs'] = (int)(bool)$this->query('select path from '.$this->DB_TableName.' where isdir=1 and path='.$this->DB->quote(strtolower($raw['path'])));
@@ -648,14 +648,14 @@  discard block
 block discarded – undo
648 648
 	}
649 649
 
650 650
 	/**
651
-	* Recursive files search
652
-	*
653
-	* @param  string  $path   dir path
654
-	* @param  string  $q      search string
655
-	* @param  array   $mimes
656
-	* @return array
657
-	* @author Naoki Sawada
658
-	**/
651
+	 * Recursive files search
652
+	 *
653
+	 * @param  string  $path   dir path
654
+	 * @param  string  $q      search string
655
+	 * @param  array   $mimes
656
+	 * @return array
657
+	 * @author Naoki Sawada
658
+	 **/
659 659
 	protected function doSearch($path, $q, $mimes) {
660 660
 		$result = array();
661 661
 		$sth = $this->DB->prepare('select dat from '.$this->DB_TableName.' WHERE path LIKE ? AND fname LIKE ?');
@@ -679,16 +679,16 @@  discard block
 block discarded – undo
679 679
 	}
680 680
 	
681 681
 	/**
682
-	* Copy file/recursive copy dir only in current volume.
683
-	* Return new file path or false.
684
-	*
685
-	* @param  string  $src   source path
686
-	* @param  string  $dst   destination dir path
687
-	* @param  string  $name  new file name (optionaly)
688
-	* @return string|false
689
-	* @author Dmitry (dio) Levashov
690
-	* @author Naoki Sawada
691
-	**/
682
+	 * Copy file/recursive copy dir only in current volume.
683
+	 * Return new file path or false.
684
+	 *
685
+	 * @param  string  $src   source path
686
+	 * @param  string  $dst   destination dir path
687
+	 * @param  string  $name  new file name (optionaly)
688
+	 * @return string|false
689
+	 * @author Dmitry (dio) Levashov
690
+	 * @author Naoki Sawada
691
+	 **/
692 692
 	protected function copy($src, $dst, $name) {
693 693
 
694 694
 		$this->clearcache();
@@ -699,14 +699,14 @@  discard block
 block discarded – undo
699 699
 	}
700 700
 	
701 701
 	/**
702
-	* Remove file/ recursive remove dir
703
-	*
704
-	* @param  string  $path   file path
705
-	* @param  bool    $force  try to remove even if file locked
706
-	* @return bool
707
-	* @author Dmitry (dio) Levashov
708
-	* @author Naoki Sawada
709
-	**/
702
+	 * Remove file/ recursive remove dir
703
+	 *
704
+	 * @param  string  $path   file path
705
+	 * @param  bool    $force  try to remove even if file locked
706
+	 * @return bool
707
+	 * @author Dmitry (dio) Levashov
708
+	 * @author Naoki Sawada
709
+	 **/
710 710
 	protected function remove($path, $force = false, $recursive = false) {
711 711
 		$stat = $this->stat($path);
712 712
 		$stat['realpath'] = $path;
@@ -736,14 +736,14 @@  discard block
 block discarded – undo
736 736
 	}
737 737
 	
738 738
 	/**
739
-	* Create thumnbnail and return it's URL on success
740
-	*
741
-	* @param  string  $path  file path
742
-	* @param  string  $mime  file mime type
743
-	* @return string|false
744
-	* @author Dmitry (dio) Levashov
745
-	* @author Naoki Sawada
746
-	**/
739
+	 * Create thumnbnail and return it's URL on success
740
+	 *
741
+	 * @param  string  $path  file path
742
+	 * @param  string  $mime  file mime type
743
+	 * @return string|false
744
+	 * @author Dmitry (dio) Levashov
745
+	 * @author Naoki Sawada
746
+	 **/
747 747
 	protected function createTmb($path, $stat) {
748 748
 		if (!$stat || !$this->canCreateTmb($path, $stat)) {
749 749
 			return false;
@@ -828,13 +828,13 @@  discard block
 block discarded – undo
828 828
 	}
829 829
 	
830 830
 	/**
831
-	* Return content URL
832
-	*
833
-	* @param string  $hash  file hash
834
-	* @param array $options options
835
-	* @return array
836
-	* @author Naoki Sawada
837
-	**/
831
+	 * Return content URL
832
+	 *
833
+	 * @param string  $hash  file hash
834
+	 * @param array $options options
835
+	 * @return array
836
+	 * @author Naoki Sawada
837
+	 **/
838 838
 	public function getContentUrl($hash, $options = array()) {
839 839
 		if (($file = $this->file($hash)) == false || !$file['url'] || $file['url'] == 1) {
840 840
 			$path = $this->decode($hash);
@@ -897,9 +897,9 @@  discard block
 block discarded – undo
897 897
 			try {
898 898
 				$request2 = new HTTP_Request2();
899 899
 				$request2->setConfig(array(
900
-                    'ssl_verify_peer' => false,
901
-                    'ssl_verify_host' => false
902
-                ));
900
+					'ssl_verify_peer' => false,
901
+					'ssl_verify_host' => false
902
+				));
903 903
 				$request2->setUrl($url);
904 904
 				$request2->setMethod(HTTP_Request2::METHOD_HEAD);
905 905
 				$result = $request2->send();
Please login to merge, or discard this patch.
php/elFinderVolumeFTP.class.php 1 patch
Doc Comments   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -477,7 +477,7 @@  discard block
 block discarded – undo
477 477
 	 * Return ftp transfer mode for file
478 478
 	 *
479 479
 	 * @param  string  $path  file path
480
-	 * @return string
480
+	 * @return integer
481 481
 	 * @author Dmitry (dio) Levashov
482 482
 	 **/
483 483
 	protected function ftpMode($path) {
@@ -841,7 +841,6 @@  discard block
 block discarded – undo
841 841
 	 * Open file and return file pointer
842 842
 	 *
843 843
 	 * @param  string  $path  file path
844
-	 * @param  bool    $write open file for writing
845 844
 	 * @return resource|false
846 845
 	 * @author Dmitry (dio) Levashov
847 846
 	 **/
@@ -866,7 +865,7 @@  discard block
 block discarded – undo
866 865
 	 * Close opened file
867 866
 	 *
868 867
 	 * @param  resource  $fp  file pointer
869
-	 * @return bool
868
+	 * @return boolean|null
870 869
 	 * @author Dmitry (dio) Levashov
871 870
 	 **/
872 871
 	protected function _fclose($fp, $path='') {
@@ -883,7 +882,7 @@  discard block
 block discarded – undo
883 882
 	 *
884 883
 	 * @param  string  $path  parent dir path
885 884
 	 * @param string  $name  new directory name
886
-	 * @return string|bool
885
+	 * @return false|string
887 886
 	 * @author Dmitry (dio) Levashov
888 887
 	 **/
889 888
 	protected function _mkdir($path, $name) {
@@ -901,7 +900,7 @@  discard block
 block discarded – undo
901 900
 	 *
902 901
 	 * @param  string  $path  parent dir path
903 902
 	 * @param string  $name  new file name
904
-	 * @return string|bool
903
+	 * @return string|false
905 904
 	 * @author Dmitry (dio) Levashov
906 905
 	 **/
907 906
 	protected function _mkfile($path, $name) {
@@ -933,7 +932,7 @@  discard block
 block discarded – undo
933 932
 	 * @param  string  $source     source file path
934 933
 	 * @param  string  $targetDir  target directory path
935 934
 	 * @param  string  $name       new file name
936
-	 * @return bool
935
+	 * @return string|false
937 936
 	 * @author Dmitry (dio) Levashov
938 937
 	 **/
939 938
 	protected function _copy($source, $targetDir, $name) {
@@ -958,9 +957,9 @@  discard block
 block discarded – undo
958 957
 	 * Return new file path or false.
959 958
 	 *
960 959
 	 * @param  string  $source  source file path
961
-	 * @param  string  $target  target dir path
960
+	 * @param  string  $targetDir  target dir path
962 961
 	 * @param  string  $name    file name
963
-	 * @return string|bool
962
+	 * @return string|false
964 963
 	 * @author Dmitry (dio) Levashov
965 964
 	 **/
966 965
 	protected function _move($source, $targetDir, $name) {
@@ -998,7 +997,7 @@  discard block
 block discarded – undo
998 997
 	 * @param  string    $dir  target dir path
999 998
 	 * @param  string    $name file name
1000 999
 	 * @param  array     $stat file stat (required by some virtual fs)
1001
-	 * @return bool|string
1000
+	 * @return string|false
1002 1001
 	 * @author Dmitry (dio) Levashov
1003 1002
 	 **/
1004 1003
 	protected function _save($fp, $dir, $name, $stat) {
@@ -1231,7 +1230,7 @@  discard block
 block discarded – undo
1231 1230
 	 * @param  array   $files  files names list
1232 1231
 	 * @param  string  $name   archive name
1233 1232
 	 * @param  array   $arc    archiver options
1234
-	 * @return string|bool
1233
+	 * @return false|string
1235 1234
 	 * @author Dmitry (dio) Levashov,
1236 1235
 	 * @author Alexey Sukhotin
1237 1236
 	 **/
@@ -1350,9 +1349,9 @@  discard block
 block discarded – undo
1350 1349
 	 * Downloads specified files from remote directory
1351 1350
 	 * if there is a directory among files it is downloaded recursively (omitting symbolic links).
1352 1351
 	 * 
1353
-	 * @param $remote_directory string remote FTP path to a source directory to download from.
1352
+	 * @param string $remote_directory string remote FTP path to a source directory to download from.
1354 1353
 	 * @param array $files list of files to download from remote directory.
1355
-	 * @param $dest_local_directory string destination folder to store downloaded files.
1354
+	 * @param string $dest_local_directory string destination folder to store downloaded files.
1356 1355
 	 * @return bool true on success and false on failure.
1357 1356
 	 */
1358 1357
 	private function ftp_download_files($remote_directory, array $files, $dest_local_directory)
@@ -1423,6 +1422,7 @@  discard block
 block discarded – undo
1423 1422
 	 * Returns array of strings containing all files and folders in the specified local directory.
1424 1423
 	 * @param $dir
1425 1424
 	 * @param string $prefix
1425
+	 * @param boolean $omitSymlinks
1426 1426
 	 * @internal param string $path path to directory to scan.
1427 1427
 	 * @return array array of files and folders names relative to the $path
1428 1428
 	 * or an empty array if the directory $path is empty,
Please login to merge, or discard this patch.
php/elFinderVolumeLocalFileSystem.class.php 1 patch
Doc Comments   +7 added lines, -8 removed lines patch added patch discarded remove patch
@@ -593,7 +593,6 @@  discard block
 block discarded – undo
593 593
 	 * Open file and return file pointer
594 594
 	 *
595 595
 	 * @param  string  $path  file path
596
-	 * @param  bool    $write open file for writing
597 596
 	 * @return resource|false
598 597
 	 * @author Dmitry (dio) Levashov
599 598
 	 **/
@@ -619,7 +618,7 @@  discard block
 block discarded – undo
619 618
 	 *
620 619
 	 * @param  string  $path  parent dir path
621 620
 	 * @param string  $name  new directory name
622
-	 * @return string|bool
621
+	 * @return string|false
623 622
 	 * @author Dmitry (dio) Levashov
624 623
 	 **/
625 624
 	protected function _mkdir($path, $name) {
@@ -639,7 +638,7 @@  discard block
 block discarded – undo
639 638
 	 *
640 639
 	 * @param  string  $path  parent dir path
641 640
 	 * @param string  $name  new file name
642
-	 * @return string|bool
641
+	 * @return string|false
643 642
 	 * @author Dmitry (dio) Levashov
644 643
 	 **/
645 644
 	protected function _mkfile($path, $name) {
@@ -687,9 +686,9 @@  discard block
 block discarded – undo
687 686
 	 * Return new file path or false.
688 687
 	 *
689 688
 	 * @param  string  $source  source file path
690
-	 * @param  string  $target  target dir path
689
+	 * @param  string  $targetDir  target dir path
691 690
 	 * @param  string  $name    file name
692
-	 * @return string|bool
691
+	 * @return string|false
693 692
 	 * @author Dmitry (dio) Levashov
694 693
 	 **/
695 694
 	protected function _move($source, $targetDir, $name) {
@@ -733,7 +732,7 @@  discard block
 block discarded – undo
733 732
 	 * @param  string    $dir  target dir path
734 733
 	 * @param  string    $name file name
735 734
 	 * @param  array     $stat file stat (required by some virtual fs)
736
-	 * @return bool|string
735
+	 * @return false|string
737 736
 	 * @author Dmitry (dio) Levashov
738 737
 	 **/
739 738
 	protected function _save($fp, $dir, $name, $stat) {
@@ -761,7 +760,7 @@  discard block
 block discarded – undo
761 760
 	 * Get file contents
762 761
 	 *
763 762
 	 * @param  string  $path  file path
764
-	 * @return string|false
763
+	 * @return string
765 764
 	 * @author Dmitry (dio) Levashov
766 765
 	 **/
767 766
 	protected function _getContents($path) {
@@ -965,7 +964,7 @@  discard block
 block discarded – undo
965 964
 	 * @param  array   $files  files names list
966 965
 	 * @param  string  $name   archive name
967 966
 	 * @param  array   $arc    archiver options
968
-	 * @return string|bool
967
+	 * @return string|false
969 968
 	 * @author Dmitry (dio) Levashov, 
970 969
 	 * @author Alexey Sukhotin
971 970
 	 **/
Please login to merge, or discard this patch.
php/elFinderVolumeMySQL.class.php 1 patch
Doc Comments   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -611,7 +611,7 @@  discard block
 block discarded – undo
611 611
 	 * Close opened file
612 612
 	 *
613 613
 	 * @param  resource  $fp  file pointer
614
-	 * @return bool
614
+	 * @return boolean|null
615 615
 	 * @author Dmitry (dio) Levashov
616 616
 	 **/
617 617
 	protected function _fclose($fp, $path='') {
@@ -628,7 +628,7 @@  discard block
 block discarded – undo
628 628
 	 *
629 629
 	 * @param  string  $path  parent dir path
630 630
 	 * @param string  $name  new directory name
631
-	 * @return string|bool
631
+	 * @return string|false
632 632
 	 * @author Dmitry (dio) Levashov
633 633
 	 **/
634 634
 	protected function _mkdir($path, $name) {
@@ -640,7 +640,7 @@  discard block
 block discarded – undo
640 640
 	 *
641 641
 	 * @param  string  $path  parent dir path
642 642
 	 * @param string  $name  new file name
643
-	 * @return string|bool
643
+	 * @return string|false
644 644
 	 * @author Dmitry (dio) Levashov
645 645
 	 **/
646 646
 	protected function _mkfile($path, $name) {
@@ -684,9 +684,9 @@  discard block
 block discarded – undo
684 684
 	 * Return new file path or false.
685 685
 	 *
686 686
 	 * @param  string  $source  source file path
687
-	 * @param  string  $target  target dir path
687
+	 * @param  string  $targetDir  target dir path
688 688
 	 * @param  string  $name    file name
689
-	 * @return string|bool
689
+	 * @return string|false
690 690
 	 * @author Dmitry (dio) Levashov
691 691
 	 **/
692 692
 	protected function _move($source, $targetDir, $name) {
@@ -869,7 +869,7 @@  discard block
 block discarded – undo
869 869
 	 *
870 870
 	 * @param  string  $path  archive path
871 871
 	 * @param  array   $arc   archiver command and arguments (same as in $this->archivers)
872
-	 * @return true
872
+	 * @return boolean
873 873
 	 * @author Dmitry (dio) Levashov, 
874 874
 	 * @author Alexey Sukhotin
875 875
 	 **/
@@ -884,7 +884,7 @@  discard block
 block discarded – undo
884 884
 	 * @param  array   $files  files names list
885 885
 	 * @param  string  $name   archive name
886 886
 	 * @param  array   $arc    archiver options
887
-	 * @return string|bool
887
+	 * @return boolean
888 888
 	 * @author Dmitry (dio) Levashov, 
889 889
 	 * @author Alexey Sukhotin
890 890
 	 **/
Please login to merge, or discard this patch.
php/elFinderVolumeS3.class.php 1 patch
Doc Comments   +7 added lines, -8 removed lines patch added patch discarded remove patch
@@ -368,7 +368,6 @@  discard block
 block discarded – undo
368 368
 	 * Open file and return file pointer
369 369
 	 *
370 370
 	 * @param  string  $path  file path
371
-	 * @param  bool    $write open file for writing
372 371
 	 * @return resource|false
373 372
 	 * @author Dmitry (dio) Levashov,
374 373
 	 * @author Alexey Sukhotin
@@ -407,7 +406,7 @@  discard block
 block discarded – undo
407 406
 	 * 
408 407
 	 * @param  resource  $fp    file pointer
409 408
 	 * @param  string    $path  file path
410
-	 * @return bool
409
+	 * @return boolean|null
411 410
 	 * @author Dmitry (dio) Levashov
412 411
 	 **/
413 412
 	protected function _fclose($fp, $path='') {
@@ -492,7 +491,7 @@  discard block
 block discarded – undo
492 491
 	 * Copy file into another file (only inside one volume)
493 492
 	 *
494 493
 	 * @param  string  $source  source file path
495
-	 * @param  string  $target  target dir path
494
+	 * @param  string  $targetDir  target dir path
496 495
 	 * @param  string  $name    file name
497 496
 	 * @return bool
498 497
 	 * @author Dmitry (dio) Levashov
@@ -506,9 +505,9 @@  discard block
 block discarded – undo
506 505
 	 * Return new file path or false.
507 506
 	 *
508 507
 	 * @param  string  $source  source file path
509
-	 * @param  string  $target  target dir path
508
+	 * @param  string  $targetDir  target dir path
510 509
 	 * @param  string  $name    file name
511
-	 * @return string|bool
510
+	 * @return boolean
512 511
 	 * @author Dmitry (dio) Levashov
513 512
 	 **/
514 513
 	protected function _move($source, $targetDir, $name) {
@@ -573,7 +572,7 @@  discard block
 block discarded – undo
573 572
 	 * @param  resource  $fp   file pointer
574 573
 	 * @param  string    $dir  target dir path
575 574
 	 * @param  string    $name file name
576
-	 * @return bool|string
575
+	 * @return boolean
577 576
 	 * @author Dmitry (dio) Levashov
578 577
 	 **/
579 578
 	protected function _save($fp, $dir, $name, $mime, $stat) {
@@ -584,7 +583,7 @@  discard block
 block discarded – undo
584 583
 	 * Get file contents
585 584
 	 *
586 585
 	 * @param  string  $path  file path
587
-	 * @return string|false
586
+	 * @return boolean
588 587
 	 * @author Dmitry (dio) Levashov
589 588
 	 **/
590 589
 	protected function _getContents($path) {
@@ -623,7 +622,7 @@  discard block
 block discarded – undo
623 622
 	 * @param  array   $files  files names list
624 623
 	 * @param  string  $name   archive name
625 624
 	 * @param  array   $arc    archiver options
626
-	 * @return string|bool
625
+	 * @return boolean
627 626
 	 * @author Dmitry (dio) Levashov, 
628 627
 	 * @author Alexey Sukhotin
629 628
 	 **/
Please login to merge, or discard this patch.
php/plugins/AutoResize/plugin.php 2 patches
Doc Comments   +8 added lines patch added patch discarded remove patch
@@ -107,6 +107,10 @@  discard block
 block discarded – undo
107 107
 		}
108 108
 	}
109 109
 	
110
+	/**
111
+	 * @param double $width
112
+	 * @param double $height
113
+	 */
110 114
 	private function resize_gd($src, $width, $height, $quality, $srcImgInfo) {
111 115
 		switch ($srcImgInfo['mime']) {
112 116
 			case 'image/gif':
@@ -177,6 +181,10 @@  discard block
 block discarded – undo
177 181
 		return false;
178 182
 	}
179 183
 	
184
+	/**
185
+	 * @param double $width
186
+	 * @param double $height
187
+	 */
180 188
 	private function resize_imagick($src, $width, $height, $quality) {
181 189
 		try {
182 190
 			$img = new imagick($src);
Please login to merge, or discard this patch.
Indentation   +44 added lines, -44 removed lines patch added patch discarded remove patch
@@ -1,49 +1,49 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * elFinder Plugin AutoResize
4
- *
5
- * Auto resize on file upload.
6
- *
7
- * ex. binding, configure on connector options
8
- *	$opts = array(
9
- *		'bind' => array(
10
- *			'upload.presave' => array(
11
- *				'Plugin.AutoResize.onUpLoadPreSave'
12
- *			)
13
- *		),
14
- *		// global configure (optional)
15
- *		'plugin' => array(
16
- *			'PluginAutoResize' => array(
17
- *				'enable'         => true,       // For control by volume driver
18
- *				'maxWidth'       => 1024,       // Path to Water mark image
19
- *				'maxHeight'      => 1024,       // Margin right pixel
20
- *				'quality'        => 95,         // JPEG image save quality
21
- *				'targetType'     => IMG_GIF|IMG_JPG|IMG_PNG|IMG_WBMP // Target image formats ( bit-field )
22
- *			)
23
- *		),
24
- *		// each volume configure (optional)
25
- *		'roots' => array(
26
- *			array(
27
- *				'driver' => 'LocalFileSystem',
28
- *				'path'   => '/path/to/files/',
29
- *				'URL'    => 'http://localhost/to/files/'
30
- *				'plugin' => array(
31
- *					'PluginAutoResize' => array(
32
- *						'enable'         => true,       // For control by volume driver
33
- *						'maxWidth'       => 1024,       // Path to Water mark image
34
- *						'maxHeight'      => 1024,       // Margin right pixel
35
- *						'quality'        => 95,         // JPEG image save quality
36
- *						'targetType'     => IMG_GIF|IMG_JPG|IMG_PNG|IMG_WBMP // Target image formats ( bit-field )
37
- *					)
38
- *				)
39
- *			)
40
- *		)
41
- *	);
42
- *
43
- * @package elfinder
44
- * @author Naoki Sawada
45
- * @license New BSD
46
- */
3
+	 * elFinder Plugin AutoResize
4
+	 *
5
+	 * Auto resize on file upload.
6
+	 *
7
+	 * ex. binding, configure on connector options
8
+	 *	$opts = array(
9
+	 *		'bind' => array(
10
+	 *			'upload.presave' => array(
11
+	 *				'Plugin.AutoResize.onUpLoadPreSave'
12
+	 *			)
13
+	 *		),
14
+	 *		// global configure (optional)
15
+	 *		'plugin' => array(
16
+	 *			'PluginAutoResize' => array(
17
+	 *				'enable'         => true,       // For control by volume driver
18
+	 *				'maxWidth'       => 1024,       // Path to Water mark image
19
+	 *				'maxHeight'      => 1024,       // Margin right pixel
20
+	 *				'quality'        => 95,         // JPEG image save quality
21
+	 *				'targetType'     => IMG_GIF|IMG_JPG|IMG_PNG|IMG_WBMP // Target image formats ( bit-field )
22
+	 *			)
23
+	 *		),
24
+	 *		// each volume configure (optional)
25
+	 *		'roots' => array(
26
+	 *			array(
27
+	 *				'driver' => 'LocalFileSystem',
28
+	 *				'path'   => '/path/to/files/',
29
+	 *				'URL'    => 'http://localhost/to/files/'
30
+	 *				'plugin' => array(
31
+	 *					'PluginAutoResize' => array(
32
+	 *						'enable'         => true,       // For control by volume driver
33
+	 *						'maxWidth'       => 1024,       // Path to Water mark image
34
+	 *						'maxHeight'      => 1024,       // Margin right pixel
35
+	 *						'quality'        => 95,         // JPEG image save quality
36
+	 *						'targetType'     => IMG_GIF|IMG_JPG|IMG_PNG|IMG_WBMP // Target image formats ( bit-field )
37
+	 *					)
38
+	 *				)
39
+	 *			)
40
+	 *		)
41
+	 *	);
42
+	 *
43
+	 * @package elfinder
44
+	 * @author Naoki Sawada
45
+	 * @license New BSD
46
+	 */
47 47
 class elFinderPluginAutoResize {
48 48
 
49 49
 	private $opts = array();
Please login to merge, or discard this patch.
php/plugins/Watermark/plugin.php 1 patch
Indentation   +50 added lines, -50 removed lines patch added patch discarded remove patch
@@ -1,55 +1,55 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * elFinder Plugin Watermark
4
- *
5
- * Print watermark on file upload.
6
- *
7
- * ex. binding, configure on connector options
8
- *	$opts = array(
9
- *		'bind' => array(
10
- *			'upload.presave' => array(
11
- *				'Plugin.Watermark.onUpLoadPreSave'
12
- *			)
13
- *		),
14
- *		// global configure (optional)
15
- *		'plugin' => array(
16
- *			'Watermark' => array(
17
- *				'enable'         => true,       // For control by volume driver
18
- *				'source'         => 'logo.png', // Path to Water mark image
19
- *				'marginRight'    => 5,          // Margin right pixel
20
- *				'marginBottom'   => 5,          // Margin bottom pixel
21
- *				'quality'        => 95,         // JPEG image save quality
22
- *				'transparency'   => 70,         // Water mark image transparency ( other than PNG )
23
- *				'targetType'     => IMG_GIF|IMG_JPG|IMG_PNG|IMG_WBMP, // Target image formats ( bit-field )
24
- *				'targetMinPixel' => 200         // Target image minimum pixel size
25
- *			)
26
- *		),
27
- *		// each volume configure (optional)
28
- *		'roots' => array(
29
- *			array(
30
- *				'driver' => 'LocalFileSystem',
31
- *				'path'   => '/path/to/files/',
32
- *				'URL'    => 'http://localhost/to/files/'
33
- *				'plugin' => array(
34
- *					'Watermark' => array(
35
- *			 			'enable'         => true,       // For control by volume driver
36
- *						'source'         => 'logo.png', // Path to Water mark image
37
- *						'marginRight'    => 5,          // Margin right pixel
38
- *						'marginBottom'   => 5,          // Margin bottom pixel
39
- *						'quality'        => 95,         // JPEG image save quality
40
- *						'transparency'   => 70,         // Water mark image transparency ( other than PNG )
41
- *						'targetType'     => IMG_GIF|IMG_JPG|IMG_PNG|IMG_WBMP, // Target image formats ( bit-field )
42
- *						'targetMinPixel' => 200         // Target image minimum pixel size
43
- *					)
44
- *				)
45
- *			)
46
- *		)
47
- *	);
48
- *
49
- * @package elfinder
50
- * @author Naoki Sawada
51
- * @license New BSD
52
- */
3
+	 * elFinder Plugin Watermark
4
+	 *
5
+	 * Print watermark on file upload.
6
+	 *
7
+	 * ex. binding, configure on connector options
8
+	 *	$opts = array(
9
+	 *		'bind' => array(
10
+	 *			'upload.presave' => array(
11
+	 *				'Plugin.Watermark.onUpLoadPreSave'
12
+	 *			)
13
+	 *		),
14
+	 *		// global configure (optional)
15
+	 *		'plugin' => array(
16
+	 *			'Watermark' => array(
17
+	 *				'enable'         => true,       // For control by volume driver
18
+	 *				'source'         => 'logo.png', // Path to Water mark image
19
+	 *				'marginRight'    => 5,          // Margin right pixel
20
+	 *				'marginBottom'   => 5,          // Margin bottom pixel
21
+	 *				'quality'        => 95,         // JPEG image save quality
22
+	 *				'transparency'   => 70,         // Water mark image transparency ( other than PNG )
23
+	 *				'targetType'     => IMG_GIF|IMG_JPG|IMG_PNG|IMG_WBMP, // Target image formats ( bit-field )
24
+	 *				'targetMinPixel' => 200         // Target image minimum pixel size
25
+	 *			)
26
+	 *		),
27
+	 *		// each volume configure (optional)
28
+	 *		'roots' => array(
29
+	 *			array(
30
+	 *				'driver' => 'LocalFileSystem',
31
+	 *				'path'   => '/path/to/files/',
32
+	 *				'URL'    => 'http://localhost/to/files/'
33
+	 *				'plugin' => array(
34
+	 *					'Watermark' => array(
35
+	 *			 			'enable'         => true,       // For control by volume driver
36
+	 *						'source'         => 'logo.png', // Path to Water mark image
37
+	 *						'marginRight'    => 5,          // Margin right pixel
38
+	 *						'marginBottom'   => 5,          // Margin bottom pixel
39
+	 *						'quality'        => 95,         // JPEG image save quality
40
+	 *						'transparency'   => 70,         // Water mark image transparency ( other than PNG )
41
+	 *						'targetType'     => IMG_GIF|IMG_JPG|IMG_PNG|IMG_WBMP, // Target image formats ( bit-field )
42
+	 *						'targetMinPixel' => 200         // Target image minimum pixel size
43
+	 *					)
44
+	 *				)
45
+	 *			)
46
+	 *		)
47
+	 *	);
48
+	 *
49
+	 * @package elfinder
50
+	 * @author Naoki Sawada
51
+	 * @license New BSD
52
+	 */
53 53
 class elFinderPluginWatermark {
54 54
 
55 55
 	private $opts = array();
Please login to merge, or discard this patch.