rogernem
August 12th, 2009, 01:06 PM
In my code:
$command = 'C:\xampp\mysql\bin\mysqldump --host='.$host.' --user='.$user.' --password='.$pass.' --all-databases | gzip > databasebackup.sql.gz';
system($command);
does not work. It creates the file databasebackup.sql.gz but when I try to open it I get "Invalid archive directory"
If I leave just $command = 'C:\xampp\mysql\bin\mysqldump --host='.$host.' --user='.$user.' --password='.$pass.' --all-databases > databasebackup.sql'; it works.
It creates the file databasebackup.sql and I can open it without a problem.
Any ideas what is wrong?
$command = 'C:\xampp\mysql\bin\mysqldump --host='.$host.' --user='.$user.' --password='.$pass.' --all-databases | gzip > databasebackup.sql.gz';
system($command);
does not work. It creates the file databasebackup.sql.gz but when I try to open it I get "Invalid archive directory"
If I leave just $command = 'C:\xampp\mysql\bin\mysqldump --host='.$host.' --user='.$user.' --password='.$pass.' --all-databases > databasebackup.sql'; it works.
It creates the file databasebackup.sql and I can open it without a problem.
Any ideas what is wrong?