2

Is there an easy php function to backup a database (or set of tables within a database) to another mysql installation or within the same database but to other tables?

Michael
  • 4,282
  • 9
  • 55
  • 89
  • Boy, would my life be easier if there was... – Rijk Sep 04 '11 at 16:36
  • 1
    You can call the "mysqldump" program from PHP. http://stackoverflow.com/questions/1867797/php-script-to-backup-mysql-database – Gus Sep 04 '11 at 16:45
  • You can visit https://codecanyon.net/ and search for "Simple Backup" - you will find several Scripts that fit your needs. – adilbo Jun 20 '18 at 06:17

2 Answers2

4

You can try this

http://davidwalsh.name/backup-mysql-database-php

modify the code to back it up to other database.

2

No but you could use PHPmyAdmin or any other MySQL tool which supports export. You might also write your own.

str
  • 42,689
  • 17
  • 109
  • 127