1

When I create a zip I:

  • right click on that folder
  • we can see the option to add to archive
  • click on that option

  • before click on OK - see that below there is an option for splitting into volumes. Select any size and then click on OK and it will create a multipart zip file.

After the creation of the multipart zip file we can extract any one of them and it will exact the whole thing and give us the original folder with all the data.

I want to do this with php code but can't get it to work. Please help.

Ben Rhys-Lewis
  • 3,118
  • 8
  • 34
  • 45
Queen queen
  • 65
  • 2
  • 10
  • are you referring to the Window Right Click context menu of 7-zip -> add to archive...? because i don't see this with the default windows compressed (zipped) folder option – Memor-X Aug 17 '16 at 06:51
  • i create zip of one folder in multiple part . but when i extract one zip then it extract only that zip contain not hole zip contain . please tell me how can we do it in php – Queen queen Aug 17 '16 at 07:02
  • **I figured out how to do it**, at least for my usage: https://stackoverflow.com/a/76692295/1599699 – Andrew Jul 15 '23 at 05:08

1 Answers1

0

I might be wrong, but I don't think it's possible using php. At least I never encountered this possibility using ZipArchive or Zip Functions

vincenth
  • 1,732
  • 5
  • 19
  • 27
  • there is one example in ZipArchive : link http://php.net/ziparchive . Simple class xZip to zip big folders into multiple parts and unzip multi zip files at once. it provide answer for multipart but with number of file . not size for zip. – Queen queen Aug 19 '16 at 08:35
  • Indeed, you might want to modify that code to suit your need. The idea would be to get the zip size after adding a file and creating a new one if it exceeds requested size. – vincenth Aug 19 '16 at 08:52