Sat
Jun
25
There's been a bug with using the Turkish locale tr_TR in PHP since 2002
At some point internally, PHP converts function and class names to their lowercase equivalent. According to this page, Turkish has two forms of the letter “i”, which are apparently not interchangeable.
This all, of course, means that any function or class with a capital “i” in it’s name will appear undefined when using a Turkish locale. Fun!
The simplest workaround seems to be just setting
LC_CTYPEback toen_USwhen using thetr_TRlocale.
Or maybe just en instead, since the entire world actually doesn’t revolve around America.