fix: search engine reset

This commit is contained in:
2013-10-29 21:44:17 +01:00
parent 2661e933da
commit 46aa984c2a
3 changed files with 11 additions and 26 deletions

View File

@@ -168,27 +168,6 @@ if($bUserOk && $sAction!=Databap::EXT_ACCESS)
$oMySqlInstall = new MySqlManager();
$sResult = $oMySqlInstall->getFullInstallQuery();
break;
case 'fix_encoding':
/**
* Procedure (from ISO-8859-1, aka Latin-1)
* - Re-encode all tables from database using utf8_encode()
* - Alter database and change database generation script in MySqlManager :
* - ALTER DATABASE databap CHARACTER SET utf8 COLLATE utf8_general_ci;
* - (ALTER TABLE tablename CHARACTER SET utf8 COLLATE utf8_general_ci;)
* - CREATE DATABASE `my_db` CHARACTER SET = utf8 COLLATE = utf8_general_ci;
* - (CREATE TABLE `my_table` ([TABLE spec]) CHARACTER SET = utf8 COLLATE = utf8_general_ci;)
* - Convert existing database :
* - mysqldump --default_character_set=latin1 -u root -p my_db > my_db.sql
* - iconv -f iso-8859-1 -t utf8 my_db.sql > my_db-utf8.sql
* - sed s/latin1/utf8/ < my_db-utf8.sql > my_db-utf8-final.sql
* - CREATE DATABASE `my_db` CHARACTER SET = utf8 COLLATE = utf8_general_ci;
* - mysql -u root -p my_db < my_db-utf8-final.sql
* - check http://webcollab.sourceforge.net/unicode.html
* - add mb_* function : sudo apt-get install php-mbstring --> check http://allseeing-i.com/How-to-setup-your-PHP-site-to-use-UTF8
* - replace strlen with ToolBox::strlen() --> check the so called mb_* functions
*/
$sResult = $oDatabap->fixEncoding();
break;
}
}
}