Witam, czy znacie może jakieś DZIAŁAJĄCE skrypty które automatycznie zrzucają bazę danych?
Pozdrawiam!
<?php ?>
function create_backup_file($file_name_backup, $drop = false) { $query = 'SHOW TABLES'; $struct_table[$table] = ''; $struct_table[$table] .= "\r\n\r\n# Struktura tabeli: ".$table."\r\n\r\n\r\n"; foreach($struct as $tbl) if($drop) { $struct_table[$table] .= 'DROP TABLE IF EXISTS `'.$table."`;\r\n"; $struct_table[$table] .= $tbl. ";\r\n\r\n"; } else $struct_table[$table] .= $tbl. ";\r\n\r\n"; } $table_zaw = "-------------------------------\r\n"; $table_zaw .= '-- Zawartosc tabeli: '.$table."\r\n"; $table_zaw .= "-------------------------------\r\n\r\n\r\n"; $col_names= ''; $values = ''; for($i = 0; $i < $num; $i++) { if($type == "tinyint" || $type == "smallint" || $type == "mediumint" || $type == "int" || $type == "bigint" || $type == "timestamp") $values.= $row2[$i].', '; else $values .= "'$row2[$i]'".', '; } $insert = "INSERT INTO ".$table."(".$col_names.") VALUES(".$values.");\r\n"; } } } function download_file($file_backup) { }