• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Custom Email Validation Rule

semprot

Active member
#1
How to make custom email validation rule (in registration, updating email info by the user himself etc) ?

For example, if the user inputs email with any "+", an error message will be displayed "Email should not contain any plus sign".

And if the user inputs email with more than 3 dots, another error message will be displayed "Email should not contain more than 3 dots."

Thank you :)
 

semprot

Active member
#3
Just an update. I think i find out how to achieve it.

I think i need to edit this file :
Code:
/library/XenForo/Helper/Email.php
In this function
Code:
public static function isEmailValid($email)
I have not tried, i will test it soon ;)