Want to get involved in developing SMF, then why not lend a hand on our github!
Started by JayBachatero, January 08, 2007, 09:39:10 PM
Quote<H> I had zero posts when I started posting
Quote from: Kiri` Von Antertynwae on October 23, 2007, 01:56:19 AMYea, but didn't work...
Quote from: target_locked on December 03, 2007, 03:57:58 AMHi All,I can not backup and restore my DB with UTF-8 charset in PHPMyadmin, there is no option for UTF-8?After backup and restore, the UTF-8 collation become "latin1_swedish_ci" and my Vietnamese language can not be displayed correctly. How to change it back to UTF-8?Any one experienced this, pls advice.Thanks.
Quote from: Sarge on December 03, 2007, 06:27:17 AMGo to SMF Admin > Forum Maintenance and run "Convert the database and data to UTF-8". If this option is not available and you have "Convert HTML-entities to UTF-8 characters" instead, but the collation of your DB tables and table fields is latin1_swedish_ci, you probably have to delete the global_character_set variable from the table smf_settings in phpMyAdmin; then you should see the option "Convert the database and data to UTF-8".See this post for more info:http://www.simplemachines.org/community/index.php?topic=166743.msg1151417#msg1151417Hopefully it will work for you!
Quote from: target_locked on December 03, 2007, 11:47:38 PMThat doesn't work.After run "Convert the database and data to UTF-8" and come back to forum, everything is same.I just want to back up my current DB (which is working normally) 100% exactly the same, but after deleting the DB and restore/import it by PHPMyadmin, it become different DB.
Quote from: Naglfar on December 17, 2007, 05:15:58 PMSarge, you have solved designer0307's problem. Can you write how you did that?
Quote from: Sarge on December 18, 2007, 02:28:18 AMWhat is selected as the (Character) Encoding (from the View menu) in your browser when you go to your phpBB forum?
mysql_query("SET NAMES $db_character_set");
mysql_query("SET NAMES latin2");
Quote from: newk on March 19, 2008, 02:18:55 PMIs choosing UTF-8 when importing database in PHPmyadmin another way to convert database to UTF-8?
QuoteHere's what I did for designer0307. I'm not sure if the guide below applies in your case, so let me know how it goes for you.0) First, get a full backup of the database, including the structure. I suggest getting a backup from cPanel, if you have it, but backups from phpMyAdmin should be OK too. Be sure to test the downloaded backup, to make sure it's not corrupted -- this can happen, for example, when the download has been interrupted. This is very important!1) Install SMF using the default options. Do not select UTF-8 in the install page. If you install SMF on a different database than the phpBB installation, make sure that the database user for SMF has access to the phpBB database.2) Download the UTF-8 Converter (convert.php) attached to this post:http://www.simplemachines.org/community/index.php?topic=140917.msg1023841#msg1023841Open it in a text editor. Find:Code: [Select]mysql_query("SET NAMES $db_character_set");Replace with:Code: [Select]mysql_query("SET NAMES latin2");If it doesn't work, try latin1 instead of latin2.Save it as cvt_latin2.php (or cvt_latin1.php) after making the change and upload it to the main directory of your SMF forum. Also upload the latest phpbb2_to_smf.sql, attached to this post:http://www.simplemachines.org/community/index.php?topic=142124.msg905972#msg9059723) Run the converter as usual, for example from this URL:http://www.yoursite.com/smf/cvt_latin2.phpDelete cvt_latin2.php after the conversion.Let me know if you get any errors during the conversion.4) After the conversion has been finished successfully, go to Admin (Administracja in Polish) --> Forum Maintenance (Obsluga forum). Click on "Convert the database and data to UTF-8" (Przekonwertuj baze danych i dane na UTF-8). In the next page, select ISO-8859-2 (if it doesn't work, select ISO-8859-1) for "Data character set" (Standard kodowania danych) and click the Proceed (Dalej) button.5) After the UTF-8 conversion has finished, upload the Polish UTF-8 language pack files.6) Switch the language to Polish in your profile or in Admin > Server Settings (Ustawienia serwera) > "Default Forum Language" (Domyslny jezyk forum) to Polish.Note 1: Since characters are already converted to UTF-8, I think SMF displays posted Polish characters correctly even when using the English language pack, maybe even with other language-utf8 packs.Note 2: After conversion, character (page) encoding in your browser should be selected as Unicode (UTF-8). Central European (ISO-8859-2) doesn't work for UTF-8 characters, except for the English alphabet and some other common characters.Let me know if you find any problems with the above, or if you need more information.