[TYPO3-core] [Fwd: RFC: Bug 5550: 'lower' TCA specification may fail with non-ascii characters]

Martin Kutschker martin.kutschker-n0spam at no5pam-blackbox.net
Sat May 12 16:43:51 CEST 2007

Dmitry Dulepov schrieb:
> Reminder :)
> -------- Original Message --------
> Subject: [TYPO3-core] RFC: Bug 5550: 'lower' TCA specification may fail 
> with non-ascii characters
> Date: Mon, 07 May 2007 15:05:32 +0300
> From: Dmitry Dulepov <9f4eetb02 at sneakemail.com>
> Newsgroups: typo3.teams.core
> Hi!
> This is SVN patch request.
> Problem: "lower" specification in TCA's "eval" may cause string cut
> after non-ascii character. Reason for this is that it uses strtolower
> and not multibyte handling functions.
> Problem: use conversion routine from csConv object of $LANG.
> Note: this also changes $LANG to be officially required by TCEMain.
> Earlier it was required as well (see post by Masi some days ago) but it
> was said different in the header of the file. In reality core always
> uses template.php when it uses TCEMain and template.php makes $LANG
> global. So should do well-behaving extensions. I expect we are safe with
> this "de-facto-existing" requirement.
> This fix is needed by fix for bug 689 (Domain Record with umlaut Domains
> not working)



PS: If we want we can create a copy of t3lib_cs in the constructor or 
init function like this:

$this->charset = BE[forceCharset] ? BE[forceCharset] :'iso-8859-1';
if (is_object($GLOBALS['LANG'])) {
   $this->charset =
   $this->csConvObj &= $GLOBALS['LANG']->csConvObj;
} else {
   $this->csConvObj = t3lib_div::makeInstance('t3lib_cs');

After that the caller may then switch to any charset he likes.


More information about the TYPO3-team-core mailing list