To create a client side of validation, you need to find a regular expression on which Laravel validates email .
In which file is the use of regular expressions?
To create a client side of validation, you need to find a regular expression on which Laravel validates email .
In which file is the use of regular expressions?
Why check email on a regular schedule if there is a good filter_var function?
Laravel of the same opinion, and they do not use the regular season:
/** * Validate that an attribute is a valid e-mail address. * * @param string $attribute * @param mixed $value * @return bool */ public function validateEmail($attribute, $value) { return filter_var($value, FILTER_VALIDATE_EMAIL) !== false; } Link to the method itself: https://github.com/laravel/framework/blob/5.6/src/Illuminate/Validation/Concerns/ValidatesAttributes.php#L590
Source: https://ru.stackoverflow.com/questions/840872/
All Articles