[TYPO3-dev] charset troubles when inserting data manually into table, how to detect and handle that?

Martin Kutschker masi-no at spam-typo3.org
Sat Sep 13 16:34:00 CEST 2008


Dmitry Dulepov [typo3] schrieb:
> Hi!
> 
> Cyrill Helg wrote:
>> yes, ok. But how can I get the current charset of the installation? It
>> would be nice to just have a function that takes care of it....
> 
> The charset of the database is $TYPO3_CONF_VARS['BE']['forceCharset'].
> If that is empty, use iso-8859-1.

Not quite right. In the BE the charset is defined by the language of the
BE user, so it may be any charset. In the FE it's defined by TS.

See Steffen's post for more info (though in the FE you should use
$TSFE->renderCharset and not $TSFE->defaultCharset which is always
iso-8859-1).

Masi




More information about the TYPO3-dev mailing list