When a user signs up with a mobile phone,
An invalid e-mail, warning will be shown.
An extra space is being added when a user is typing his/her e-mail and then selecting the typed ahead e-mail.
How can I adjust the client side e-mail validation, that it will trim the value first, before client side validation.
Or how and where, can I override de default E-mail validator and what should the regex look like?
On Server side this is handeld bij de trim rule…
here are my email rules
public function rules() {
return [
//...
['email', 'filter', 'filter' => 'trim'],
['email', 'required'],
['email', 'email'],
['email', 'unique', 'targetClass' => '\common\models\User', 'message' => 'This email is allready in use'],
//...
}