I need a very very basic PHP script/page that will dump a MySQL database into a zip file for download.
It needs to do EXACTLY what phpMyAdmin does on a database export when one selects "SQL" as the export type and checks "Save as file" and selects "zipped" as the compression.
One could in essence just pull that code out of phpMyAdmin and I would need it set up that I just pass a URL var to the page created which would be the file name to be saved as and then it starts the download.
In the top of the file I would like the necessary config parameters for the database connection:
$username
$password
$host
$database
Then as mentioned previous I would pass it a URL var $file_name or something and that is it.
It will be used on an existing extranet for the users to manually do a daily backup of the database, but I can't let them use the shared host's phpMyAdmin. Nothing fancy. They currently have one, but it does not zip the file so the download takes to long.
phpMyAdmin compresses their DB to 2.8M currently.
Should be a quick and easy job.
## Deliverables
1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done.
2) Deliverables must be in ready-to-run condition, as follows (depending on the nature of the deliverables):
a) For web sites or other server-side deliverables intended to only ever exist in one place in the Buyer's environment--Deliverables must be installed by the Seller in ready-to-run condition in the Buyer's environment.
b) For all others including desktop software or software the buyer intends to distribute: A software installation package that will install the software in ready-to-run condition on the platform(s) specified in this bid request.
3) All deliverables will be considered "work made for hire" under U.S. Copyright law. Buyer will receive exclusive and complete copyrights to all work purchased. (No GPL, GNU, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site per the coder's Seller Legal Agreement).
## Platform
MySQL 4.1, PHP 4.3, Apache