[Typo3] Did typo3 3.8 compatible to mysql 4.1??

Dennis Cheung hkdennis2k at gmail.com
Wed Nov 23 04:04:21 CET 2005


>Yes. Logically that should be set automatically to utf-8 if you set:
>$TYPO_CONF_VARS[BE][forceCharset] = utf-8
It is utf8 from the very beginning of installation of typo3.



I've patch the class.t3lib_db.php

Just insert two queries
        @mysql_query('SET NAMES utf8',$this->link);
        @mysql_query('SET CHARACTER SET utf8',$this->link);
after pconnect
and then everything work fine (not included I have to fix all exists text in
database).

I think we may need some auto detection of mysql server and what charset
typo3/db are using.

thanks,
Dennis



On 11/21/05, Elmar Hinz <elmar.DOT.hinz at team.minus.red.dot.net> wrote:
>
> > for example. mysql 4.1 unicode compatible.
> > I didn't notice that before I saw some character broken.
> > And I found, mysqld using utf8, typo3 using utf8, but mysql_connect
> using
> > iso-8859-1.
> > All chinese character are broken inside database,
> > (one utf8 character from typo3 it convert into three 8859-1 char, and
> then
> > convert one 8859-1 char into one utf character again)
> >
>
> I did some testing my own and come to similar results.
>
> * DB MySQL 4.1.11, Collation utf8_unicode_ci
> * TYPO3 3.8.0
>
> Setup: page.config.metaCharset = utf-8
> Config: $[BE][forceCharset]=utf-8;
>
> As long as I enter iso chars editing and output works fine.
> But non ascii chars look *ugly* in the database in phpMyAdmin is set to
> utf-8.
>
> When I try to enter chinese or russian letters, I get an error window
> directly after submit:
>
> 102: These fields are not properly updated in database: (bodytext)
> Probably value mismatch with fieldtype.
>
> A few days ago there was a discussion about a russian site. They needed
> to setup the DB as iso-8859-1 to get a utf-8 site running. That sounds
> paradox in some way and can't be the regular solution.
>
> It may be that "SET NAMES 'charset_name'" don't work as Dennis suspected
> in his first posting. Maybe it should bette be "SET CHARACTER SET
> charset_name".
>
> Elmar
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> --
> Climate change 2005: Mexico, Guatemala, New Orleans, Sahel, Bangladesh,
> Spain, Portugal, Austria, Swiss, France, ...
> Production of CO2 is killing people.
> Production of CO2 just for fun is killing people just for fun.
> _______________________________________________
> Typo3-english mailing list
> Typo3-english at lists.netfielders.de
> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english
>



More information about the TYPO3-english mailing list