[TYPO3-core] RFC #8591: Umlauts get broken in shortcut menu while renaming the shortcut

Tobias Liebig mail_news at etobi.de
Mon Jun 9 21:46:05 CEST 2008


Martin Kutschker wrote:
> Tobias Liebig schrieb:
>>  
>> +            // get charset from current ajax request (which is
>> expected to be utf-8)
>> +        preg_match('/.*; charset=(.*)$/i',
>> strtolower($_SERVER["CONTENT_TYPE"]), $contenttype);
> 
> You don't need strtolower if you use the i modifier.
> 
> The content type should be safe (because set by some friendly code), but
>  your regexp matches ALL after the = (incl. any white space and further
> header content).
> 
> Maybe you can use this $GLOBALS['LANG']->csConvObj->parse_charset() if
> you expect variant spellings of the charsets. It will do the trimming
> and case lowering as well.

Attached to this post you'll find a new version of the patch, which
consider Masi's helpful hints.

regards
   tobias

-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch_ajax_20080609_8591_b.diff
Type: text/x-patch
Size: 1240 bytes
Desc: not available
Url : http://lists.netfielders.de/pipermail/typo3-team-core/attachments/20080609/10ee6230/attachment.bin 


More information about the TYPO3-team-core mailing list