isimpledesign Posted February 22, 2011 Share Posted February 22, 2011 hi all i am looking for the quickest way to zip all files and folder of a website i am currently using the followning. <?php $date = date("F-j-Y-g-ia"); if(exec("cd /home/isd/public_html/bk/files;tar -cvpzf backup-$date.tar /home/isd/public_html")) { echo "done"; } ?> This works but was just wondering if anyone can give me and insight on a better solution?? Thanks Quote Link to comment https://forums.phpfreaks.com/topic/228481-quickest-backup-solution-to-zip-all-files-and-folders/ Share on other sites More sharing options...
trq Posted February 23, 2011 Share Posted February 23, 2011 I don't see a better solution if that is working for you. I generally would do these things from a prompt but I understand why some people prefer to execute script via a http request. Quote Link to comment https://forums.phpfreaks.com/topic/228481-quickest-backup-solution-to-zip-all-files-and-folders/#findComment-1178453 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.