Make WordPress Core

Changes between Version 1 and Version 2 of Ticket #31992, comment 8


Ignore:
Timestamp:
11/12/2020 05:25:52 PM (4 years ago)
Author:
prfidneai
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #31992, comment 8

    v1 v2  
    55As I can see, nothing was changed with EAI for 6 years from the time this ticket was open and Unicode EAI cannot be used in WP.  I would like to propose some things to fix it:
    66
    7 1)      Let's modify sanitize_email() and is_email() to use special constants for regex check username and domain name WP_IDN_LOCAL_MAIL_REGEX and  WP_IDN_DOMAIN_REGEX in default-constants.php which every admin can change to validate IDN domains rules for language he uses. For example I added Russian IDN rules to these regexes.
     71)      Let's modify sanitize_email() and is_email() to use special constants in default-constants.php for regex check username and domain name (WP_IDN_LOCAL_MAIL_REGEX and  WP_IDN_DOMAIN_REGEX) which every admin can change to validate IDN domains rules for language he uses. For example I added Russian IDN rules to these regexes.
    88
    992)      Let's also add decode_punycode() to sanitize_email() function which check if e-mail domain part in Punycode from and convert it to Unicode as required by uasg.tech