Bug #60554 [Opn->Bgs]: basename() broken with Spanish locales
| From: | cataphract@php.net | Date: | Wed, 21 Dec 2011 15:59:30 +0000 |
| Subject: | Bug #60554 [Opn->Bgs]: basename() broken with Spanish locales | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-166026@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=60554&edit=1
ID: 60554
Updated by: cataphract@php.net
Reported by: yunosh@php.net
Summary: basename() broken with Spanish locales
-Status: Open
+Status: Bogus
Type: Bug
Package: Filesystem function related
PHP Version: 5.4.0RC3
Block user comment: N
Private report: N
New Comment:
basename() features this warning:
basename() is locale aware, so for it to see the correct basename with multibyte character paths,
the matching locale must be set using the setlocale() function.
As I understand, you're passign it utf-8 data while setting the locale to something else; this
is not allowed.
Previous Comments:
------------------------------------------------------------------------
[2011-12-18 16:06:31] yunosh@php.net
Description:
------------
See test script.
Test script:
---------------
LANG=es_ES php -r
'var_dump(basename("é«&æ§&è¡&å&ç&æ&é .xls"));'
Expected result:
----------------
é«&æ§&è¡&å&ç&æ&é .xls
Actual result:
--------------
&æ§&è¡&å&ç&æ&é .xls
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=60554&edit=1