We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 33085
    • 11 Posts
    Charts like à è é ù ’ and so on, when saved they change in different charts.

    If I try to save ’учреждения’ the result is ’учреждениÑ?’.
    If I try to save ’à’ the result is ’Ã’.
    Obvliously this is not a problem in WYSIWYG editor.

    I use MODx 0.9.6.3 in Italian translation.

    This is a multi languge site and it uses european and russian charts.
    The chartset used in manager is Unicode UTF-8 like mysql charts set and mysql connection collocation is utf8_unicode_ci.
    In table site_content the collocation of fields is latin1_swedish_ci.

    I come across this problem both in in back-end (manager) and in front-end.

    What should I do in order to solve this problem??

    Thanks.
      • 22303 MODX Staff
      • 10,725 Posts
      Quote from: ydraweb at Dec 26, 2008, 06:32 AM

      In table site_content the collocation of fields is latin1_swedish_ci.
      Change to latin1 encoding since that is what you are storing the content as, or install again from scratch and make sure the database is created with the proper collation before any data is inserted. Having the database indicate utf8_unicode_ci but with tables having latin1_swedish_ci is the problem and that mismatch must be solved.
        • 33085
        • 11 Posts
        Thank for your reply.
        I followed your pieces of advice but it was not enough.

        I had to edit the config.in.php file and change this line
        $database_connection_charset = ’utf8’;
        to
        $database_connection_charset = ’’;

        Now it works for me.

        Thank for having shown me the right way.
        Bye.
          • 22303 MODX Staff
          • 10,725 Posts
          Quote from: ydraweb at Dec 26, 2008, 01:55 PM

          I had to edit the config.in.php file and change this line
          $database_connection_charset = ’utf8’;
          to
          $database_connection_charset = ’’;
          That’s not really correct, it just happens to work in your environment because your database was setup improperly.

          Are you sure your collations on the database and the tables match now? If they were latin1_swedish_ci, then you need to change the database to latin1_swedish_ci and set the database_connection_charset to latin1. But that would also require you to use an appropriate latin1-compatible encoding to present your content. Or, you could try to use SET NAMES and leave the connection_charset value at utf8 to attempt to translate your content back and forth to utf8 even though it is stored in latin1.