#31801 [Opn->Asn]: localeconv returns wrong LC_NUMERIC settings

From: Date: Wed, 02 Feb 2005 07:38:51 +0000
Subject: #31801 [Opn->Asn]: localeconv returns wrong LC_NUMERIC settings
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-73241@lists.php.net to get a copy of this message
ID: 31801 Updated by: derick@php.net Reported By: jordi at jcanals dot net -Status: Open +Status: Assigned Bug Type: *Languages/Translation Operating System: Linux PHP Version: 5.0.3 -Assigned To: +Assigned To: derick Previous Comments: ------------------------------------------------------------------------ [2005-02-02 01:44:23] jordi at jcanals dot net Description: ------------ The localeconv() provides wrong information in some locales It produces wrong results for the es_ES and ca_ES locales. As I only provide one example, in both locales I get the same wrong result, and for both, the same correct result below shoud be returned. This was solved for the locale de_DE as a solution to the bug #30638 (Now for de_DE it returns the correct values). On windows with the equivalent locales it returns the correct results. Windows equivalents are: Spanish for es_ES and Catalan for ca_ES. Reproduce code: --------------- <?php setlocale(LC_ALL, 'es_ES'); $lc = localeconv(); echo '<pre>'; print_r($lc); echo '</pre>'; ?> Expected result: ---------------- Array ( [decimal_point] => , [thousands_sep] => . [int_curr_symbol] => EUR [currency_symbol] => EUR [mon_decimal_point] => , [mon_thousands_sep] => . [positive_sign] => [negative_sign] => - [int_frac_digits] => 2 [frac_digits] => 2 [p_cs_precedes] => 0 [p_sep_by_space] => 1 [n_cs_precedes] => 0 [n_sep_by_space] => 1 [p_sign_posn] => 1 [n_sign_posn] => 1 [grouping] => Array ( [0] => 3 [1] => 3 ) [mon_grouping] => Array ( [0] => 3 [1] => 3 ) ) Note: This is the same result that provides other european languages like de_DE Actual result: -------------- Array ( [decimal_point] => , [thousands_sep] => [int_curr_symbol] => EUR [currency_symbol] => EUR [mon_decimal_point] => , [mon_thousands_sep] => . [positive_sign] => [negative_sign] => - [int_frac_digits] => 2 [frac_digits] => 2 [p_cs_precedes] => 1 [p_sep_by_space] => 1 [n_cs_precedes] => 1 [n_sep_by_space] => 1 [p_sign_posn] => 1 [n_sign_posn] => 1 [grouping] => Array ( ) [mon_grouping] => Array ( [0] => 3 [1] => 3 ) ) Note: Both locales es_ES and ca_ES provide the same wrong result. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=31801&edit=1

« previous php.bugs (#73241) next »