WordPress.org

Support

Support » Plugins and Hacks » Duplicator » [Resolved] [Plugin: Duplicator] Not working right with non-latin UTF-8 character set

[Resolved] [Plugin: Duplicator] Not working right with non-latin UTF-8 character set

  • I use the latest version of Duplicator 0.2.5
    and get the wrong character when install (Thai Language).
    Ex. ��سҾ���

    I also check “Enable database character encoding” On the options dialog.

    I looking in database.sql file. Everything look correct.
    So I edited install.php at line 469.

    $conn = @mysql_connect($dbhost, $dbuser, $dbpassword)
    			or die(sprintf(MSG_FAIL_DBCONNECT, mysql_error()) . $tryagain_html);

    add this after:

    mysql_query("SET NAMES 'utf8' ");

    Perfect! everything install correctly 🙂

    I assume that some machine has no utf-8 as default character set. so I force that. This might help other or maybe you can put in next version.

    Thanks.

    http://wordpress.org/extend/plugins/duplicator/

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author Cory Lamle

    @corylamleorg

    Hey supersuphot,

    That’s great! I’ll get this integrated into the next versions…

    Thanks!

    I have same problem with russian language.
    Ex. ? ?????????
    What line I should edit in current version 0.2.9 and where insert mysql_query(“SET NAMES ‘utf8’ “);?

    Thanks!

    Plugin Author Cory Lamle

    @corylamleorg

    Hi dreamstone,

    To use Unicode character sets on your site please make sure to do the following:

    1. When creating a package, be sure that in the options dialog the checkbox ‘Enable database encoding’ is unchecked

    2. When running the installer make sure the checkbox for ‘Enable MySQL character set’ is checked

    Let me know if that works for you.

    Thanks

    Hi lifeinthegrid!

    You are right! It works now!!!

    Thanks!

    Plugin Author Cory Lamle

    @corylamleorg

    Hey dreamstone,

    Thats great! Let me know if you come across any others issues with characters sets.

    Thanks

    Hi Lifeinthegrid,

    Same problem here with Turkish character ç ü ğ ö etc. I use WP 3.4.1, Duplicator 0.3.1 .

    I follow the orders

    1. When creating a package, be sure that in the options dialog the checkbox ‘Enable database encoding’ is unchecked

    2. When running the installer make sure the checkbox for ‘Enable MySQL character set’ is checked

    I look around the installer.php and i see that you use mysqli and i couldn’t find any bug. I focus line 134

    $dbmysqlichar = (isset($_POST['dbmysqlichar']) && $_POST['dbmysqlichar'] == '1')  	? true : false;

    line 723-726

    if ($dbmysqlichar) {
        mysqli_set_charset( $mysqli_conn, "{$GLOBALS['MYSQL_CHARSET']}");
        dinstaller_log("MySql: charater set enabled to '{$GLOBALS['MYSQL_CHARSET']}'\n");
    		}

    And Advanced Opts form line 1010 – 1024.

    Is there any way to work around this problem? Or I miss something?

    Thanks.

    Plugin Author Cory Lamle

    @corylamleorg

    Hey onur,

    The fix for this is in the developer line. Just reinstall that version and it should work. It should also be available in 0.3.2 when it is released…

    The same problem on czech language on version 0.3.1!
    Thanx to onur.ozgur.ozkan your solution works perfect!!!
    Thank you

    Plugin Author Cory Lamle

    @corylamleorg

    When using the older mysql libs “UTF-8” was the required string. Updating to mysqli it required “utf8”. I thought I had covered this in testing but somehow it got overlooked sorry about the confusion!

    Cheers!

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘[Resolved] [Plugin: Duplicator] Not working right with non-latin UTF-8 character set’ is closed to new replies.
Skip to toolbar