ID: 18556 Comment by: cankoy at ymail dot com Reported By: spud at nothingness dot org Status: No Feedback Bug Type: Scripting Engine problem Operating System: Linux (RedHat 7.2) PHP Version: 5CVS, 4CVS (2005-10-04) Assigned To: andrei New Comment:
Setting LC_CTYPE to something other than tr_TR solves nothing, it's not even a workaround, you just get a bastardized locale in which regex patterns do not match Turkish char.s and XXlower/XXupper functions become nothing but a joke. This bug has been around for ages, so it's not fixable? OK, don't fix it, but at least provide a means to turn off(*) the horrible PHP design decision "case-insensitive function lookup", so that we have an option to avoid all this mess. (*)like, a Php.ini directive Previous Comments: ------------------------------------------------------------------------ [2009-07-30 17:21:41] onur dot oguzel at gmail dot com i guess nobody looks at this bug, setlocale(LC_ALL, 'tr_TR'); setlocale(LC_CTYPE, 'en_US'); sure solves this but it is still a bug :) ------------------------------------------------------------------------ [2009-06-18 09:51:52] spam at pamignot dot org This bug is still alive !! Can someone have a look to this ? While it is not fixed, you can set LC_CTYPE to another locale to get it works again. ------------------------------------------------------------------------ [2009-03-05 19:28:22] cankoy at ymail dot com This also occurs in function names: <?php echo setlocale(LC_ALL, 'tr_TR')."\n"; HI5(); function HI5() { echo "Five!\n";} ?> outputs: --- tr_TR Fatal error: Call to undefined function HI5() in... --- whereas the following works OK: <?php echo setlocale(LC_ALL, 'tr_TR')."\n"; function HI5() { echo "Five!\n";} HI5(); ?> outputs: --- tr_TR Five! --- using php-cli 5.2.6 on Ubuntu 8.10. ------------------------------------------------------------------------ [2008-05-20 07:44:31] c dot muench at netz98 dot de This bug is still alive in version 5.2.5. I tested the posted script and get the same results. ------------------------------------------------------------------------ [2008-04-21 18:40:05] jreeve at pelagodesign dot com We are still getting this bug with PHP 5.2.3 PHP 5.2.3 (cli) (built: Feb 7 2008 06:40:06) As noted below, this function: <?php echo setlocale(LC_ALL, "tr_TR.utf8")."\n"; foreach(get_declared_classes() as $class) { if(!class_exists($class)) echo "$class No Longer Exists!\n"; } ?> Produces this error: tr_TR.utf8 DOMImplementationList No Longer Exists! DOMImplementationSource No Longer Exists! DOMImplementation No Longer Exists! DOMProcessingInstruction No Longer Exists! RecursiveIteratorIterator No Longer Exists! IteratorIterator No Longer Exists! FilterIterator No Longer Exists! RecursiveFilterIterator No Longer Exists! ParentIterator No Longer Exists! LimitIterator No Longer Exists! CachingIterator No Longer Exists! RecursiveCachingIterator No Longer Exists! NoRewindIterator No Longer Exists! AppendIterator No Longer Exists! InfiniteIterator No Longer Exists! RegexIterator No Longer Exists! RecursiveRegexIterator No Longer Exists! EmptyIterator No Longer Exists! ArrayIterator No Longer Exists! RecursiveArrayIterator No Longer Exists! SplFileInfo No Longer Exists! DirectoryIterator No Longer Exists! RecursiveDirectoryIterator No Longer Exists! SimpleXMLIterator No Longer Exists! InvalidArgumentException No Longer Exists! __PHP_Incomplete_Class No Longer Exists! ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/18556 -- Edit this bug report at http://bugs.php.net/?id=18556&edit=1