That would not work on hosts similar to webhotels where you don't have your own server/config-persmissions.
One possibility when dumping would be to do backup in 2000 bit chunks with automatic naming like: backup_0-2000.sql, backup 2001-4000.sql or with a userdefined value if the host can take a higer value (the user could experiment on this)
An alternate would be to make the script dump the to a local dir within the admin-dir via the fputs (?) and just append to the file in 4k chunks.
Same with restore, to have an option to read a file in a local file-path with fopen and let it read in 4K chunks.
This way the sql-file can be accessed via ftp.