Customize: Use get_user_locale() in customizer body class.

Otherwise CSS specific to the site's locale would be applied, even though the customizer is displayed in the user's locale.

See #29783.
Fixes #40271.

Merges [40368] to the 4.7 branch.

Built from https://develop.svn.wordpress.org/branches/4.7@40369


git-svn-id: http://core.svn.wordpress.org/branches/4.7@40276 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Pascal Birchler 2017-04-05 02:16:34 +00:00
parent 5a10b5c879
commit a394c05654
2 changed files with 2 additions and 2 deletions

View File

@ -102,7 +102,7 @@ if ( $wp_customize->is_ios() ) {
if ( is_rtl() ) {
$body_class .= ' rtl';
}
$body_class .= ' locale-' . sanitize_html_class( strtolower( str_replace( '_', '-', get_locale() ) ) );
$body_class .= ' locale-' . sanitize_html_class( strtolower( str_replace( '_', '-', get_user_locale() ) ) );
$admin_title = sprintf( $wp_customize->get_document_title_template(), __( 'Loading…' ) );

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.7.4-alpha-40367';
$wp_version = '4.7.4-alpha-40369';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.