Ec (2); php repair table and optimize data table ------------------------ repair table functionEbak_Rep ($ tablename, $ dbname) {& nbsp; global $ empire; & nbsp; $ dbnameRepPostVar ($ dbname ); & nbsp; $ empire-& gt; query (& quot; use '$ dbname' & quo script ec (2); script
Php repair tables and optimize data tables
// -------------------------- Repair the table
Function Ebak_Rep ($ tablename, $ dbname ){
Global $ empire;
$ Dbname = RepPostVar ($ dbname );
$ Empire-> query ("use '$ dbname "');
$ Count = count ($ tablename );
If (empty ($ count ))
{
Printerror ("EmptyChangeTb", "history. go (-1 )");
}
For ($ I = 0; $ I <$ count; $ I ++)
{
$ Sql1 = $ empire-> query ("repair table '$ tablename [$ I]';");
}
Printerror ("RepairTbSuccess", "ChangeTable. php? Mydbname = $ dbname ");
}
// -------------------------- Worried table
Function Ebak_Opi ($ tablename, $ dbname ){
Global $ empire;
$ Dbname = RepPostVar ($ dbname );
$ Empire-> query ("use '$ dbname "');
$ Count = count ($ tablename );
If (empty ($ count ))
{
Printerror ("EmptyChangeTb", "history. go (-1 )");
}
For ($ I = 0; $ I <$ count; $ I ++)
{
$ Sql1 = $ empire-> query ("optimize table '$ tablename [$ I]';");
}
Printerror ("OptimizeTbSuccess", "ChangeTable. php? Mydbname = $ dbname ");
}