Opened 6 years ago
Last modified 3 years ago
#1484293 new Feature Requests
Addition ; real online e-mail validation as option for the user?
| Reported by: | seansan | Owned by: | |
|---|---|---|---|
| Priority: | 5 | Milestone: | later |
| Component: | Core functionality | Version: | git-master |
| Severity: | minor | Keywords: | mail address verification |
| Cc: |
Description (last modified by thomasb)
From devshed.com - looks good for people who want to have this. Online verification of the mail adresses. Very easy to implement.
We can add an option in config that defaults to 0 - so it is taken along development but does not trouble starting users
0 = off
1 = only DNS (MX record check)
2 = port check on remote mail server
function checkEmail($email) {
// checks proper syntax
if(preg_match("/^( [a-zA-Z0-9] )+( [a-zA-Z0-9\._-] )*@( [a-zA-Z0-9_-] )+( [a-zA-Z0-9\._-] +)+$/" , $email)) {
// gets domain name
list($username,$domain)=split('@',$email);
// checks for if MX records in the DNS
if(!checkdnsrr($domain, 'MX')) {
return false;
}
// attempts a socket connection to mail server
if(!fsockopen($domain,25,$errno,$errstr,30)) {
return false;
}
return true;
}
return false;
}
Change History (3)
comment:1 Changed 6 years ago by thomasb
- Description modified (diff)
- Milestone changed from 0.1-rc1 to 0.1.5
comment:2 Changed 5 years ago by thomasb
- Milestone changed from 0.2.5 to later
comment:3 Changed 3 years ago by Lazlo
Note: See
TracTickets for help on using
tickets.

This ticket can be closed, implemented in http://trac.roundcube.net/changeset/3042