[wp-trac] [WordPress Trac] #16023: get_locale() should correct a shortened WPLANG

WordPress Trac wp-trac at lists.automattic.com
Wed Dec 29 15:31:05 UTC 2010


#16023: get_locale() should correct a shortened WPLANG
--------------------------+-----------------------------
 Reporter:  nacin         |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  I18N          |    Version:
 Severity:  normal        |   Keywords:  has-patch
--------------------------+-----------------------------
 Some locales have distributed WPLANG in wp-config-sample with incorrect
 values. For example NL used `nl` for a WPLANG value from 3.0 to 3.0.2.
 They now use `nl_NL`, but the damage has been done for new installs during
 that time.

 One, on the wp.org side, we should check for a full WPLANG, matching the
 expression `[a-z][a-z]_[A-Z][A-Z]` and reject the build if it fails.

 Two, get_locale() should correct for a shorthand WPLANG. More or less, if
 it's two characters (xy or XY), then make it the form of xy_XY.

 Thoughts?

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


More information about the wp-trac mailing list