#12739 [Opn->Csd]: strtolower/strtoupper and special characters

From: Date: Sat, 21 Dec 2002 16:32:47 +0000
Subject: #12739 [Opn->Csd]: strtolower/strtoupper and special characters
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-28155@lists.php.net to get a copy of this message
ID: 12739 Updated by: moriyoshi@php.net Reported By: stefan.priebsch@e-novative.de -Status: Open +Status: Closed Bug Type: Feature/Change Request Operating System: all PHP Version: 4.0.6 New Comment: Since 4.3.0, you can use mb_strtoupper(), mb_strtolower(), or mb_convert_case() for that purpose. Closing... Previous Comments: ------------------------------------------------------------------------ [2001-08-14 08:49:01] stefan.priebsch@e-novative.de Special characters are not converted by strtolower/strtoupper unless I set the appropriate locale. However, in an international website the user interface language might be English, whereas the user still enters German data with umlauts. In this case it is not really possible to switch locale (as it is not known up front which language the user enters - might as well be his Swedish name) to correctly convert all special characters. I suggest extending strtoupper and strtolower in a way that ALL special characters (at least all those appearing in the Western Standard charset) are ALWAYS converted correctly. That can't do any bad because the user (programmer) would always except the functions just to upper/lowercase ALL alphabetic characters, special characters included. If the performance impact on strtoupper/strtolower is too big, it would always be possible to introduce special functions for that or have the user give a reference to the character set that the input is ... I guess your ideas are way better than mine here. In my opinion this would be a major improvement to PHP's international capabilities. Keep up the good work, anyway! Cheers, Steve ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=12739&edit=1

« previous php.bugs (#28155) next »