tao-test/app/vendor/respect/validation/docs/rules/Regex.md

25 lines
454 B
Markdown
Raw Normal View History

2022-08-29 20:14:13 +02:00
# Regex
- `v::regex(string $regex)`
Evaluates a regex on the input and validates if matches
```php
v::regex('/[a-z]/')->validate('a'); // true
```
Message template for this validator includes `{{regex}}`
***
See also:
* [Alnum](Alnum.md)
* [Alpha](Alpha.md)
* [Contains](Contains.md)
* [Digit](Digit.md)
* [EndsWith](EndsWith.md)
* [PhpLabel](PhpLabel.md)
* [Roman](Roman.md)
* [StartsWith](StartsWith.md)
* [Version](Version.md)