Last Updated | | Ratings | | Unique User Downloads | | Download Rankings |
2022-10-29 (1 month ago)  | | Not yet rated by the users | | Total: 11 | | Not yet ranked |
|
Description | | Author |
This package implements file and directory validation rules.
It provides a class that implements several rules to validate the path of files and directories.
Currently, it can validate a path:
- Can only be a directory
- Can only be a file
- Can only be under a given base directory | |
 |
|
Innovation award
 Nominee: 9x |
|
Details
Yii2 Validators Collection
- PathValidator
public function rules(){
return [
[['pathAttribute'],PathValidator::class,'strictDir'=>true],
[['pathAttribute'],PathValidator::class,'strictFile'=>true,'writeable'=>true],
[['pathAttribute'],PathValidator::class,'requiredBase'=>'@common/data','readable'=>true],
];
}
Installation
run
composer require --prefer-dist "insolita/yii2-validatorpack:~0.0.2"
or add
"insolita/yii2-validatorpack": "~0.0.2"
|
Applications that use this package |
|
No pages of applications that use this class were specified.
If you know an application of this package, send a message to the author to add a link here.