[wp-trac] [WordPress Trac] #31992: sanitize_email() and is_email() preg_replace/preg_match problems
    WordPress Trac 
    noreply at wordpress.org
       
    Fri Apr 17 16:36:04 UTC 2015
    
    
  
#31992: sanitize_email() and is_email() preg_replace/preg_match problems
-------------------------------+------------------------------
 Reporter:  ysalame            |       Owner:
     Type:  defect (bug)       |      Status:  new
 Priority:  normal             |   Milestone:  Awaiting Review
Component:  Formatting         |     Version:  trunk
 Severity:  normal             |  Resolution:
 Keywords:  reporter-feedback  |     Focuses:
-------------------------------+------------------------------
Comment (by ysalame):
 ugh... sorry. I actually pasted the email that was sanitized.
 The test I made was
 {{{
 $target_email = 'dummy-üñîçøðé.y.!#$%@üñîçøðé.gmail.com';
 echo $target_email.'<br>';
 echo sanitize_email($target_email).'<br>';
 echo 'is_email : '.is_email($target_email);
 }}}
 with return as
 {{{
 dummy-üñîçøðé.y.!#$%@üñîçøðé.gmail.com
 dummy-email.y.!#$%@gmail.com
 is_email :
 }}}
 The unicode characters were all removed. For international emails this can
 be a real problem.
 ps. I actually used the Wiki page you sent as a base for my ticket. I
 tried a mix of one of the last examples in the "Valid email Examples"
 list.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/31992#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
    
    
More information about the wp-trac
mailing list