Admin screen strings need to be sanitised to work with chinese chars Closes #4788

This commit is contained in:
Mike Jolley 2014-02-14 10:57:48 +00:00 committed by Coen Jacobs
parent 7afe12e696
commit 4dcea21d76
2 changed files with 2 additions and 2 deletions

View File

@ -115,7 +115,7 @@ class WC_Admin_Settings {
do_action( 'woocommerce_settings_start' );
wp_enqueue_script( 'woocommerce_settings', WC()->plugin_url() . '/assets/js/admin/settings.min.js', array( 'jquery', 'jquery-ui-datepicker', 'jquery-ui-sortable', 'iris' ), WC()->version, true );
wp_enqueue_script( 'woocommerce_settings', WC()->plugin_url() . '/assets/js/admin/settings.min.js', array( 'jquery', 'jquery-ui-datepicker', 'jquery-ui-sortable', 'iris', 'chosen' ), WC()->version, true );
wp_localize_script( 'woocommerce_settings', 'woocommerce_settings_params', array(
'i18n_nav_warning' => __( 'The changes you made will be lost if you navigate away from this page.', 'woocommerce' )

View File

@ -16,7 +16,7 @@ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
* @return array
*/
function wc_get_screen_ids() {
$wc_screen_id = strtolower( __( 'WooCommerce', 'woocommerce' ) );
$wc_screen_id = sanitize_title( __( 'WooCommerce', 'woocommerce' ) );
return apply_filters( 'woocommerce_screen_ids', array(
'toplevel_page_' . $wc_screen_id,