how to change encoding from windows-1255 to utf-8?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • BBF
    Member
    • Dec 2006
    • 48
    • 3.6.x

    [Forum] how to change encoding from windows-1255 to utf-8?

    hi,
    i want to convert my forum encoding from windows-1255 to windows-1255 (a full convert, include database).
    there is any way to do it?

    thanks!
    פורומים | קהילת פורומים | פורום | סאמפ | SAMP | GTA
  • renep
    Senior Member
    • Aug 2005
    • 596
    • 3.8.x

    #2
    Yes, but you have to convert the MySQL database outside of vBulletin (dump data and schema, edit schema, convert data with iconv, recreate database, create schema, import data). Then you have to set $config['Mysqli']['charset'] in config.php, your http header etc.
    "The lurking suspicion that something could be simplified is the world's richest source of rewarding challenges"
    - Edsger Dijkstra

    Comment

    • vikris
      Senior Member
      • Jan 2010
      • 113
      • 4.0.x

      #3
      Can you provide some sort of short tutorial about this? Thanks!
      http://www.zazdravje.com.mk

      Comment

      • Daniel.P
        Senior Member
        • Apr 2008
        • 600
        • 4.0.x

        #4
        mysqldump -u root -p --opt --default-character-set=latin1 --ignore-table=vbulletin_db.customavatar --ignore-table=vbulletin_db.customprofilepic --ignore-table=vbulletin_db.picture --ignore-table=vbulletin_db.socialgroupicon --ignore-table=vbulletin_db.socialgrouppicture vbulletin_db > vbulletin_db.sql

        mysqldump -u root -p --opt --default-character-set=latin1 vbulletin_db customavatar customprofilepic picture sigpic socialgroupicon socialgrouppicture > vbulletin_db_images.sql

        iconv -c -f windows-1255 -t utf-8 vbulletin_db.sql > vbulletin_db_utf8.sql

        mysql -u root -p DROP DATABASE vbulletin_db;
        CREATE DATABASE vbulletin_db CHARACTER SET utf8 COLLATE utf8_general_ci;

        mysql -u root -p --max_allowed_packet=1024M < vbulletin_db.sql


        try this, recommended on test server.
        born to fish forced to work

        Comment

        • vikris
          Senior Member
          • Jan 2010
          • 113
          • 4.0.x

          #5
          Thanks daniel, I'll try this.
          http://www.zazdravje.com.mk

          Comment

          • BBF
            Member
            • Dec 2006
            • 48
            • 3.6.x

            #6
            i converted my vbulletin successfully, but in some pages i get errors like:
            Warning: Invalid argument supplied for foreach() in [path]/includes/functions_user.php on line 808

            Warning: Invalid argument supplied for foreach() in [path]/includes/functions_user.php on line 808

            or

            Warning: Invalid argument supplied for foreach() in [path]/includes/adminfunctions_profilefield.php on line 242

            Warning: Invalid argument supplied for foreach() in [path]/includes/adminfunctions_profilefield.php on line 242

            how can i fix it?
            פורומים | קהילת פורומים | פורום | סאמפ | SAMP | GTA

            Comment

            • renep
              Senior Member
              • Aug 2005
              • 596
              • 3.8.x

              #7
              Originally posted by renep
              you have to convert the MySQL database outside of vBulletin
              Since I posted this, I've learned that it's not recommended en not supported to convert an existing database this way, because of serialized data in certain fields. Sorry.
              "The lurking suspicion that something could be simplified is the world's richest source of rewarding challenges"
              - Edsger Dijkstra

              Comment

              widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
              Working...