Edit report at https://bugs.php.net/bug.php?id=60554&edit=1
ID: 60554 Updated by: cataphr...@php.net Reported by: yun...@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] yun...@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