$zip = new ZipArchive(); $zip_name = time().".zip"; // Zip name $zip->open($zip_name, ZipArchive::CREATE); $zip->addFile('test.php'); $zip->close(); header('Content-type: application/zip'); header('Content-Disposition: attachment; filename="'.$zip_name.'"'); readfile($zip_name); unlink($zip_name);
Html, JAVA,DOTNET,Javascript, PHP, and JQuery Scripts and its issues with solutions
Showing posts with label create zip file. Show all posts
Showing posts with label create zip file. Show all posts
Thursday, 31 July 2014
How to create Zip file using php?
Subscribe to:
Posts (Atom)