Replace named HTML entity with decimal HTML entity
WP `esc_html()` function escapes the valid named HTML entity `ă` and this is causing problems for some state names (see issue #18355). This commit provides a workaround by replacing `ă` with its decimal HTML entity version `ă`. The WP core ticket below added a whilelist of named HTML entity but there is no explanation why some named HTML entities, like `ă`, were not included in the list and thus are escaped: https://core.trac.wordpress.org/ticket/12284 Fixes #18355
This commit is contained in:
parent
9818ed10f9
commit
5116cd0bd3
|
@ -19,24 +19,24 @@ if ( ! defined( 'ABSPATH' ) ) {
|
||||||
}
|
}
|
||||||
|
|
||||||
$states['MD'] = array(
|
$states['MD'] = array(
|
||||||
'C' => __( 'Chișinău', 'woocommerce' ),
|
'C' => __( 'Chișinău', 'woocommerce' ),
|
||||||
'BL' => __( 'Bălți', 'woocommerce' ),
|
'BL' => __( 'Bălți', 'woocommerce' ),
|
||||||
'AN' => __( 'Anenii Noi', 'woocommerce' ),
|
'AN' => __( 'Anenii Noi', 'woocommerce' ),
|
||||||
'BS' => __( 'Basarabeasca', 'woocommerce' ),
|
'BS' => __( 'Basarabeasca', 'woocommerce' ),
|
||||||
'BR' => __( 'Briceni', 'woocommerce' ),
|
'BR' => __( 'Briceni', 'woocommerce' ),
|
||||||
'CH' => __( 'Cahul', 'woocommerce' ),
|
'CH' => __( 'Cahul', 'woocommerce' ),
|
||||||
'CT' => __( 'Cantemir', 'woocommerce' ),
|
'CT' => __( 'Cantemir', 'woocommerce' ),
|
||||||
'CL' => __( 'Călărași', 'woocommerce' ),
|
'CL' => __( 'Călărași', 'woocommerce' ),
|
||||||
'CS' => __( 'Căușeni', 'woocommerce' ),
|
'CS' => __( 'Căușeni', 'woocommerce' ),
|
||||||
'CM' => __( 'Cimișlia', 'woocommerce' ),
|
'CM' => __( 'Cimișlia', 'woocommerce' ),
|
||||||
'CR' => __( 'Criuleni', 'woocommerce' ),
|
'CR' => __( 'Criuleni', 'woocommerce' ),
|
||||||
'DN' => __( 'Dondușeni', 'woocommerce' ),
|
'DN' => __( 'Dondușeni', 'woocommerce' ),
|
||||||
'DR' => __( 'Drochia', 'woocommerce' ),
|
'DR' => __( 'Drochia', 'woocommerce' ),
|
||||||
'DB' => __( 'Dubăsari', 'woocommerce' ),
|
'DB' => __( 'Dubăsari', 'woocommerce' ),
|
||||||
'ED' => __( 'Edineț', 'woocommerce' ),
|
'ED' => __( 'Edineț', 'woocommerce' ),
|
||||||
'FL' => __( 'Fălești', 'woocommerce' ),
|
'FL' => __( 'Fălești', 'woocommerce' ),
|
||||||
'FR' => __( 'Florești', 'woocommerce' ),
|
'FR' => __( 'Florești', 'woocommerce' ),
|
||||||
'GE' => __( 'UTA Găgăuzia', 'woocommerce' ),
|
'GE' => __( 'UTA Găgăuzia', 'woocommerce' ),
|
||||||
'GL' => __( 'Glodeni', 'woocommerce' ),
|
'GL' => __( 'Glodeni', 'woocommerce' ),
|
||||||
'HN' => __( 'Hîncești', 'woocommerce' ),
|
'HN' => __( 'Hîncești', 'woocommerce' ),
|
||||||
'IL' => __( 'Ialoveni', 'woocommerce' ),
|
'IL' => __( 'Ialoveni', 'woocommerce' ),
|
||||||
|
@ -48,9 +48,9 @@ $states['MD'] = array(
|
||||||
'RS' => __( 'Rîșcani', 'woocommerce' ),
|
'RS' => __( 'Rîșcani', 'woocommerce' ),
|
||||||
'SG' => __( 'Sîngerei', 'woocommerce' ),
|
'SG' => __( 'Sîngerei', 'woocommerce' ),
|
||||||
'SR' => __( 'Soroca', 'woocommerce' ),
|
'SR' => __( 'Soroca', 'woocommerce' ),
|
||||||
'ST' => __( 'Strășeni', 'woocommerce' ),
|
'ST' => __( 'Strășeni', 'woocommerce' ),
|
||||||
'SD' => __( 'Șoldănești', 'woocommerce' ),
|
'SD' => __( 'Șoldănești', 'woocommerce' ),
|
||||||
'SV' => __( 'Ștefan Vodă', 'woocommerce' ),
|
'SV' => __( 'Ștefan Vodă', 'woocommerce' ),
|
||||||
'TR' => __( 'Taraclia', 'woocommerce' ),
|
'TR' => __( 'Taraclia', 'woocommerce' ),
|
||||||
'TL' => __( 'Telenești', 'woocommerce' ),
|
'TL' => __( 'Telenești', 'woocommerce' ),
|
||||||
'UN' => __( 'Ungheni', 'woocommerce' ),
|
'UN' => __( 'Ungheni', 'woocommerce' ),
|
||||||
|
|
|
@ -19,15 +19,15 @@ $states['RO'] = array(
|
||||||
'AB' => __( 'Alba', 'woocommerce' ),
|
'AB' => __( 'Alba', 'woocommerce' ),
|
||||||
'AR' => __( 'Arad', 'woocommerce' ),
|
'AR' => __( 'Arad', 'woocommerce' ),
|
||||||
'AG' => __( 'Argeș', 'woocommerce' ),
|
'AG' => __( 'Argeș', 'woocommerce' ),
|
||||||
'BC' => __( 'Bacău', 'woocommerce' ),
|
'BC' => __( 'Bacău', 'woocommerce' ),
|
||||||
'BH' => __( 'Bihor', 'woocommerce' ),
|
'BH' => __( 'Bihor', 'woocommerce' ),
|
||||||
'BN' => __( 'Bistrița-Năsăud', 'woocommerce' ),
|
'BN' => __( 'Bistrița-Năsăud', 'woocommerce' ),
|
||||||
'BT' => __( 'Botoșani', 'woocommerce' ),
|
'BT' => __( 'Botoșani', 'woocommerce' ),
|
||||||
'BR' => __( 'Brăila', 'woocommerce' ),
|
'BR' => __( 'Brăila', 'woocommerce' ),
|
||||||
'BV' => __( 'Brașov', 'woocommerce' ),
|
'BV' => __( 'Brașov', 'woocommerce' ),
|
||||||
'B' => __( 'București', 'woocommerce' ),
|
'B' => __( 'București', 'woocommerce' ),
|
||||||
'BZ' => __( 'Buzău', 'woocommerce' ),
|
'BZ' => __( 'Buzău', 'woocommerce' ),
|
||||||
'CL' => __( 'Călărași', 'woocommerce' ),
|
'CL' => __( 'Călărași', 'woocommerce' ),
|
||||||
'CS' => __( 'Caraș-Severin', 'woocommerce' ),
|
'CS' => __( 'Caraș-Severin', 'woocommerce' ),
|
||||||
'CJ' => __( 'Cluj', 'woocommerce' ),
|
'CJ' => __( 'Cluj', 'woocommerce' ),
|
||||||
'CT' => __( 'Constanța', 'woocommerce' ),
|
'CT' => __( 'Constanța', 'woocommerce' ),
|
||||||
|
@ -48,7 +48,7 @@ $states['RO'] = array(
|
||||||
'NT' => __( 'Neamț', 'woocommerce' ),
|
'NT' => __( 'Neamț', 'woocommerce' ),
|
||||||
'OT' => __( 'Olt', 'woocommerce' ),
|
'OT' => __( 'Olt', 'woocommerce' ),
|
||||||
'PH' => __( 'Prahova', 'woocommerce' ),
|
'PH' => __( 'Prahova', 'woocommerce' ),
|
||||||
'SJ' => __( 'Sălaj', 'woocommerce' ),
|
'SJ' => __( 'Sălaj', 'woocommerce' ),
|
||||||
'SM' => __( 'Satu Mare', 'woocommerce' ),
|
'SM' => __( 'Satu Mare', 'woocommerce' ),
|
||||||
'SB' => __( 'Sibiu', 'woocommerce' ),
|
'SB' => __( 'Sibiu', 'woocommerce' ),
|
||||||
'SV' => __( 'Suceava', 'woocommerce' ),
|
'SV' => __( 'Suceava', 'woocommerce' ),
|
||||||
|
|
Loading…
Reference in New Issue