RandomHero Posted December 5, 2006 Share Posted December 5, 2006 Hi all, i'm currently using a class to generate a zip file. The class is available here[url=http://www.devco.net/archives/2005/05/24/creating_zip_files_with_php.php]http://www.devco.net/archives/2005/05/24/creating_zip_files_with_php.php[/url][code]<? require ("incl/zipfile.inc.php"); $zipfile = new zipfile(); $filedata = implode("", file("incl/zipfile.inc.php")); $zipfile->add_dir("incl/"); $zipfile->add_file($filedata, "incl/zipfile.inc.php"); ## I don't want to use that part of the script ## ## I want to store the zip file on the server ## header("Content-type: application/octet-stream"); header("Content-disposition: attachment; filename=zipfile.zip"); echo $zipfile->file();?>[/code]The way the class is programmed, it generates the zip file and with the headers it force the browser to download it.My problem is I want to use that class to zip some files on my server but I don't want to download it. I want the script to store the zip file somewhere else on the server. Unfortunately, I don't know the way to proceed, can somebody help me? Link to comment https://forums.phpfreaks.com/topic/29526-problem-storing-generated-zip-file-on-server/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.