mirror of
https://github.com/Respect/Validation.git
synced 2026-03-16 15:25:45 +01:00
564 B
564 B
MinimumAge
This is going to be deprecated, please use Age instead.
MinimumAge(int $age)MinimumAge(int $age, string $format)
Validates a minimum age for a given date.
v::minimumAge(18)->validate('1987-01-01'); // true
v::minimumAge(18, 'd/m/Y')->validate('01/01/1987'); // true
Using DateTime before is a best-practice.
Message template for this validator includes {{age}}.
Changelog
| Version | Description |
|---|---|
| 0.3.9 | Created |
See also: