hey, i wrote some code to backup tables and content of my database and a restore function, which is making some trouble
this is the line in the backup file which is maing trouble:
INSERT INTO flashbb_replacements VALUES ('22', ';-)', 'wink.gif', '', '', '', 'smilie', '', 'yes', 'yes');
the following script inserts the mysql tables into the db, but after the line above it stops until there is a new table written to the database...
also i got the error "Query Is Empty", $array[$x]!="" does not seem to work, i hope you can help
$file = @fopen($uploadfile,'r');
$content = @fread($file, filesize($uploadfile));
@fclose($file);
$array = explode(";\r\n",$content);
for($x=0;$x<sizeof($array);$x++) {
if($array[$x]!="") {
$array[$x] = trim($array[$x]);
$db->query("$array[$x]");
}
}