Did wordpress upgrade destroy all your unicode posts ?

I upgraded wordpress software for this blog to version 2.5.2. After that none of the posts that had devanagari (unicode) text looked okay. After comparing the configuration files, I discovered that the troubling variable is DB_CHARSET. The default config setting is ‘utf8′. But if you have been updating the software versions, your database table is probably in ‘latin-1′ charset, though wordpress has been saving unicode data to the tables. Once you remove the DB_CHARSET setting (or setting it to latin-1 or ”), things return to normal.

The setting is in the file wp-config.php in the wordpress install directory.
The value before change:
define(‘DB_CHARSET’, ‘utf8′);

The value after change:
//define(‘DB_CHARSET’, ‘utf8′);
define(‘DB_CHARSET’, ”);

So maybe I should try to recreate the tables with correct charset defined in mysql some day ?

Related posts:

  1. django unicode integration: fix for venus djando template
  2. wordpress themes
  3. Unicode entry
  4. Search the web for devanagari words.
  5. More about Phishtank API

Tags: , , ,

  1. B Shantanu’s avatar

    Dear Amit,
    I too had some “Devanagari” posts on my wordpress hosted blog but when I migrated to my own domain, I lost all the “devanaagari” script…

    Pl see the post below to understand what I mean

    http://satyameva-jayate.org/2008/02/19/there-is-a-rashtra-in-maharashtra/

    Can you please help? I am not very sophisticated technically

    If you wish, you can email me at jai.dharmaATgmail.com

    Thanks so much
    Shantanu

    Reply

  2. M. Liu’s avatar

    Thank you very much for posting the info! Saved me much time!

    Reply