Browse Source

Call static::mkdir(..)

tags/2.0.0-beta
Mojtaba Salehi 11 years ago
parent
commit
d97512e774
  1. 6
      framework/yii/helpers/base/FileHelper.php

6
framework/yii/helpers/base/FileHelper.php

@ -135,7 +135,7 @@ class FileHelper
* - dirMode: integer, the permission to be set for newly copied directories. Defaults to 0777. * - dirMode: integer, the permission to be set for newly copied directories. Defaults to 0777.
* - fileMode: integer, the permission to be set for newly copied files. Defaults to the current environment setting. * - fileMode: integer, the permission to be set for newly copied files. Defaults to the current environment setting.
* - filter: callback, a PHP callback that is called for each sub-directory or file. * - filter: callback, a PHP callback that is called for each sub-directory or file.
* If the callback returns false, the the sub-directory or file will not be copied. * If the callback returns false, then the sub-directory or file will not be copied.
* The signature of the callback should be: `function ($path)`, where `$path` refers the full path to be copied. * The signature of the callback should be: `function ($path)`, where `$path` refers the full path to be copied.
* - fileTypes: array, list of file name suffix (without dot). Only files with these suffixes will be copied. * - fileTypes: array, list of file name suffix (without dot). Only files with these suffixes will be copied.
* - only: array, list of patterns that the files or directories should match if they want to be copied. * - only: array, list of patterns that the files or directories should match if they want to be copied.
@ -153,7 +153,7 @@ class FileHelper
public static function copyDirectory($src, $dst, $options = array()) public static function copyDirectory($src, $dst, $options = array())
{ {
if (!is_dir($dst)) { if (!is_dir($dst)) {
mkdir($dst, isset($options['dirMode']) ? $options['dirMode'] : 0777, true); static::mkdir($dst, isset($options['dirMode']) ? $options['dirMode'] : 0777, true);
} }
$handle = opendir($src); $handle = opendir($src);
@ -210,7 +210,7 @@ class FileHelper
* @param array $options options for file searching. Valid options are: * @param array $options options for file searching. Valid options are:
* *
* - filter: callback, a PHP callback that is called for each sub-directory or file. * - filter: callback, a PHP callback that is called for each sub-directory or file.
* If the callback returns false, the the sub-directory or file will be excluded from the returning result. * If the callback returns false, then the sub-directory or file will be excluded from the returning result.
* The signature of the callback should be: `function ($path)`, where `$path` refers the full path to be filtered. * The signature of the callback should be: `function ($path)`, where `$path` refers the full path to be filtered.
* - fileTypes: array, list of file name suffix (without dot). Only files with these suffixes will be returned. * - fileTypes: array, list of file name suffix (without dot). Only files with these suffixes will be returned.
* - only: array, list of patterns that the files or directories should match if they want to be returned. * - only: array, list of patterns that the files or directories should match if they want to be returned.

Loading…
Cancel
Save