WPDK
1.5.0
WordPress Development Kit
|
Static Public Member Functions | |
static | fileSize ($filename, $precision=2) |
Get the file size. More... | |
static | recursiveScan ($path, $match= '') |
get all matched files More... | |
static | ext ($filename) |
Extension. More... | |
static | filename ($filename) |
Filename. More... | |
Static Public Member Functions inherited from WPDKObject | |
static | __delta ($last_version, $old_version) |
Object delta compare for combine. More... | |
static | delta ($last_version, $old_version) |
static | __dump ($var, $monitor=false) |
Dump a variable. More... | |
Data Fields | |
$__version = '1.1.2' | |
Version. More... | |
Data Fields inherited from WPDKObject | |
$__version = '1.0.0' | |
The version number assigned to the class. More... | |
Additional Inherited Members | |
Public Member Functions inherited from WPDKObject | |
__className () | |
Returns the class object. More... | |
__parentClass () | |
Returns the class object for the receiver’s superclass. More... | |
__isClass ($class) | |
Brief. More... | |
__isSubclassOfClass ($class) | |
Return TRUE if the receiving class is a subclass of —or identical to— $class, otherwise FALSE. More... | |
Filesystem helper.
Definition at line 12 of file wpdk-filesystem.php.
|
static |
Extension.
Return the extension of a filename
string | $filename | A comoplete filename |
Definition at line 138 of file wpdk-filesystem.php.
|
static |
Filename.
Return the only filename part. if a filename is 'test.black.jpg' will return 'test.black'
string | $filename | A comoplete filename |
Definition at line 154 of file wpdk-filesystem.php.
|
static |
Get the file size.
Return the file size well formatted.
string | $filename | File name or path to a file |
int | $precision | Digits to display after decimal |
Definition at line 33 of file wpdk-filesystem.php.
|
static |
get all matched files
Return an array with all matched files from root folder. This method release the follow filters:
wpdk_rglob_find_dir( true, $file ) - when find a dir wpdk_rglob_find_file( true, $file ) - when find a a file wpdk_rglob_matched( $regexp_result, $file, $match ) - after preg_match() done
string | $path | Folder root |
string | $match | Optional. Regex to apply on file name. For example use '/^.*.(php)$/i' to get only php file. Default is empty |
Return an array with all matched files from root folder.
get all matched files
string | $path | Folder root |
string | $match | Optional. Regex to apply on file name. For example use '/^.*.(php)$/i' to get only php file |
array | &$result | Optional. Result array. Empty form first call |
Definition at line 76 of file wpdk-filesystem.php.
string $__version = '1.1.2' |