projects
/
fa-stable.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Added chinese installer translation and updated empty.po.
[fa-stable.git]
/
admin
/
db
/
maintenance_db.inc
diff --git
a/admin/db/maintenance_db.inc
b/admin/db/maintenance_db.inc
index f1acc83aea6ec1477ce1bbfb4cab64ce6ed71040..ed14e56a1de1e438b9eef8eee6cf1baaca07fb0c 100644
(file)
--- a/
admin/db/maintenance_db.inc
+++ b/
admin/db/maintenance_db.inc
@@
-482,7
+482,7
@@
function db_backup($conn, $ext='no', $comm='', $tbpref = TB_PREF)
// generates a dump of $db database
// $drop and $zip tell if to include the drop table statement or dry to pack
// generates a dump of $db database
// $drop and $zip tell if to include the drop table statement or dry to pack
-function db_export($conn, $filename, $zip='no', $comment='', $tbpref = TB_PREF)
+function db_export($conn, $filename, $zip='no', $comment='', $tbpref = TB_PREF
, $no_default=false
)
{
global $app_title, $version, $power_url, $path_to_root;
{
global $app_title, $version, $power_url, $path_to_root;
@@
-573,6
+573,8
@@
function db_export($conn, $filename, $zip='no', $comment='', $tbpref = TB_PREF)
$out.="### Structure of table `".$tablename."` ###\n\n";
$out.="DROP TABLE IF EXISTS `".$tablename."`;\n\n";
$out.="### Structure of table `".$tablename."` ###\n\n";
$out.="DROP TABLE IF EXISTS `".$tablename."`;\n\n";
+ if ($no_default && ($def_pos = strpos($table_sql[$tablename], "DEFAULT CHARSET")) > 0)
+ $table_sql[$tablename] = substr($table_sql[$tablename], 0, $def_pos);
$out.=$table_sql[$tablename];
// add auto_increment value
$out.=$table_sql[$tablename];
// add auto_increment value