Código PHP:
<?
$filename = "tinogrm.sql";
header("Pragma: no-cache");
header("Expires: 0");
header("Content-Transfer-Encoding: binary");
header("Content-type: application/force-download");
header("Content-Disposition: attachment; filename=$filename");
$usuario="root";
$passwd="";
$bd="tinogrm.sql";
$executa = "c:\mysql\bin\mysqldump.exe -u $usuario --p $passwd --opt $bd";
// Comprobar si se a realizado bien, si no es asi, mostrará un mensaje de error
if ($executa) {
echo "Error ejecutando comando: $executa";
}
else{
header("Location: indexadmin.php");
}
?>
Error ejecutando comando: c:\mysql\bin\mysqldump.exe -u root --p --opt tinogrm.sql
Salu2
![de acuerdo](http://static.forosdelweb.com/fdwtheme/images/smilies/dedosarriba.png)