[wp-trac] [WordPress Trac] #9316: More robust is_email() and sanitize_email() functions

WordPress Trac wp-trac at lists.automattic.com
Wed Mar 11 14:58:19 GMT 2009


#9316: More robust is_email() and sanitize_email() functions
-------------------------+--------------------------------------------------
 Reporter:  sambauers    |       Owner:  anonymous 
     Type:  enhancement  |      Status:  new       
 Priority:  low          |   Milestone:  Unassigned
Component:  General      |     Version:  2.7.1     
 Severity:  minor        |    Keywords:  has-patch 
-------------------------+--------------------------------------------------
 Attached patch includes robust and filterable is_email() and
 sanitize_email() functions.

 These functions split up the validation into distinct stages rather than
 trying to use a single PCRE function. The reason for failure is made
 available via the filters.

 Also included in is_email() is an optional DNS check (where supported by
 PHP).

 Although not quite RFC compliant, it addresses most of the issues in
 #4616, and also allows easier filtering for those who want to implement
 RFC compliance via plugins.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/9316>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list