Jump to content


This topic is now archived and is closed to further replies.


Database Backup

Recommended Posts

I have a huge MySQL Database, with many tables, and data within.

Currently I backup the Database by running a dump from phpMyAdmin. I need to know the php code needed to do so automaticly (I will program it so it does so every 12 hours). I've made my own script that can backup individual tables, but need a way of backing up the whole database in one go.

I cannot use any of the methods mentioned on this site [url=http://www.php-mysql-tutorial.com/perform-mysql-backup-php.php]http://www.php-mysql-tutorial.com/perform-mysql-backup-php.php[/url], due to security features on my host.

Any help would be appreciated,


Share this post

Link to post
Share on other sites
If you can do one table, then just do this: [code]$query = mysql_query("SHOW TABLES FROM db_name_here");
while($table = mysql_fetch_row($query))
$table = $table[0];
// do your stuff here

Share this post

Link to post
Share on other sites


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.