[TYPO3-core] RFC: Fix Bug 6428 - strtoupper doesn't work with turkish i
Ingo Renner
ingo at typo3.org
Mon Oct 29 14:31:14 CET 2007
Am 29.10.2007 um 14:09 schrieb Steffen Kamper:
> ok, i prepared a function for this:
better:
public function asciiToUpper($string) {
$lowercaseCharacters = 'abcdefghijklmnopqrstuvwxyz';
$uppercaseCharacters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';
return strtr($string, $lowercaseCharacters, $uppercaseCharacters);
}
public function asciiToLower($string) {
$uppercaseCharacters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';
$lowercaseCharacters = 'abcdefghijklmnopqrstuvwxyz';
return strtr($string, $uppercaseCharacters, $lowercaseCharacters);
}
it is not good practice to mix functionality in one function while it
belongs into diferent ones.
The naming is also more clear.
BTW: t3lib_div or t3lib_cs ?
all the best
Ingo
--
TYPO3 Core Developer, Release Manager TYPO3 4.2
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2411 bytes
Desc: not available
Url : http://lists.netfielders.de/pipermail/typo3-team-core/attachments/20071029/6e2b65e4/attachment.bin
More information about the TYPO3-team-core
mailing list