Make WordPress Core

Opened 15 years ago

Closed 15 years ago

#18688 closed defect (bug) (invalid)

Blank WPLANG in multisite options won't fall back to WPLANG in wp-config.php

Reported by: eheikes Owned by:
Priority: normal Milestone:
Component: I18N Version:
Severity: normal Keywords: has-patch
Cc: Focuses:

Description

If the WPLANG option in a multisite install is a blank string (""), then the get_locale() function falls back to en_US. It seems like Wordpress should fall back to the language defined by WPLANG in the wp-config.php.

Attachments (1)

l10n.php.patch (452 bytes ) - added by eheikes 15 years ago.
Use looser checking for WPLANG options

Download all attachments as: .zip

Change History (6)

#1 follow-up: @lemats
15 years ago

Line 41 should be a "negotiated checking":

Original:

if ( $ms_locale === false )


Your patch:

if ( $ms_locale )

Fixed patch:

if ( !$ms_locale )

#2 in reply to: ↑ 1 @eheikes
15 years ago

Whoops, thanks for catching that! I'll update the patch.

@eheikes
15 years ago

Use looser checking for WPLANG options

#4 @nacin
15 years ago

  • Milestone Awaiting Review3.3

Makes sense to me. There were already some tweaks here so I'm going ahead with this.

#5 @nacin
15 years ago

  • Milestone 3.3
  • Resolutioninvalid
  • Status newclosed

Wait, no. English is indicated as '' across the board. Including when selecting a language in the dropdown, or for the WPLANG constant.

Note: See TracTickets for help on using tickets.