mirror of
https://github.com/Respect/Validation.git
synced 2026-03-18 08:09:51 +01:00
Some codes in the documentation were not code that actually works which can lead to some confusion of how to use Validation. Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
630 B
630 B
File
File()
Validates files.
v::file()->validate(__FILE__); // true
v::file()->validate(__DIR__); // false
This validator will consider SplFileInfo instances, so you can do something like:
v::file()->validate(new SplFileInfo('file.txt'));
Changelog
| Version | Description |
|---|---|
| 0.5.0 | Created |
See also: