I am on windows
I am using PHING to zip up some files
I have lots of things being zipped
Zipping works, except for ones that include a particular phing fileset in the files being zipped
When I debug, I can see in phing's ZIP Task that ZipArchive::close is returning false. The error string reads "permission denied". In the manual it stat...
I am writing an app that will need to unzip user uploaded archives. PHP provides the ZipArchive class, but it should also be possible to unzip using unzip via exec(), my question is which is preferrable in terms of performance & scaling?
...
Ok, just wondering on the versions of PHP that this class is built into. And if they are built into all platforms (OS's). I'm wanting an approach to search through a zip file and place files using file_put_contents in different filepaths within the webroot. In any case, I'm familiar with how to do this with the ZipArchive class, but I...
Hi,
I am trying to compress multiple files into a single zip archive and I am running into low memory warning. Since the complete zip file is loaded into the memory I guess that's the problem. Is there a way by which I can manage the compression/decompression better using ZipArchive so that not all the data is in the memory at once?
Th...
I am trying to load binary data as images into Word documents (Opem XML) using PHP for later usage with XSLT.
After opening the Word document as a PHP ZipArchive, I am able to load images into the word/media folder succesfully and also update the word/document.xml file. But I am unable to update the <Relationships/> in the word/rels/doc...
i have a form in which user can upload 100 mb file which results delay in upload, hence I decided to first zip the image on form submit and then upload it on server and then extract it on server. so that loading process decreases, Hence for this I have used a script which is as follows:
<?php
$zip = new ZipArchive();
$filename = "newzip...
I have a php script:
$extract_dir = "./";
$extract_file = "extractME.zip";
$zip = new ZipArchive;
$res = $zip->open($extract_file);
if ($res === TRUE) {
$zip->extractTo($extract_dir);
$zip->close();
echo "ok";
} else {
echo "failed";
}
But when I execute this script, via http://www.mywebsite.com/extract.php
All the f...
I am right at the start of trying to write some PHP code to run on a Linux box on an EC2 server that will read files from my S3 bucket, zip them then write the zip file back to the bucket.
I have instantly run in to problems with even creating a simple zip archive from some images on the local disk of the EC2 instance, I am using a scri...
Hi,
I have a problem with the php_zip.dll's ZipArchive class. I'm using it through the ZipArchiveImproved wrapper class suggested on php.net to avoid the max file-handle issue.
The problem is really simple: 700 files are added properly (jpg image files), and the rest fails. The addFile method returns false.
The PHP version is 5.2.6.
...
I'm creating a zip file in PHP for the user to download. I get no errors from PHP or from checking the zipArchive class's GetStatusString function. But if I put some files into the archive, then when I try to open it, I get the error "the compressed (zipped) folder is invalid or corrupted". I've checked all the files I'm adding, they ...
I used the function described in the following URL to create some zip files programatically which turned out to be working wonderful on the development site:
http://davidwalsh.name/create-zip-php
.
Thing is, when I uploaded the website to the production server, the file created seemed to be corrupted. winrar has given me "unexpected en...
I'm gratefully using the ZipArchive library but it seems there is a memory leak. I don't know how to fix this - it's written in C and I'm unfamiliar with it. My question is - is it possible to autorelease the line s=(unz_s*)ALLOC(sizeof(unz_s)); like you would in Objective-C in this scenario?
extern unzFile ZEXPORT unzOpen2 (path, pzlib...
Hi
I am trying to unzip a .zip file by my code. I am using ZipArchive for that one. It is wokring fine but only problem is, when I add zip file which is zipped by "winzip version 9", it extracts empty folder.
Any Idea why it is happening ?
below is my code :
$zip = new ZipArchive();
$x = $zip->open($file_to_open);
if ($x === true)...
Hi all,
I have to replace variables inside a user-submitted xlsx file and am doing it this way:
Rename the .xlsx to .zip
Unzip to a temp-folder
Make the necessary changes
Zip the files
Rename the .zip to .xslx
I am using plain ZipArchive in PHP. When I try to open the generated .xlsx in Excel, it fails with a message format or exten...
hi friends,
I have a problem that I install 'Archive_Zip 0.1.1' on Linux server, but when I try to run the script to create the zip file it gives the fatal error
"Fatal error: Class 'ZipArchive' not found in ---"
where I put the code
$zip = new ZipArchive;
var_dump($zip);
$res = $zip->open($filename, ZipArchive::OVERWRITE);
if($res !...
I may NOT bother with this but if its very simple i may consider it. The site i am working on by design is to hold hundreds of thousands of files. I dont know if we'll have only one download or multiple. Right now the choices are A) Just the file B) An archive that has the file + license and conditions.
I am trying to figure out it can ...
I'm researching solutions for a potential client. They're requesting the ability to download a large amount of MP3's (1000+) from their online catalog.
I've researched/tested building a zip containing all MP3s using ZipArchive but ran into obvious memory leak issues that have ruled that solution out.
I'm now trying to think out of the...
I am working on application for iphone that needs Compression & Encryption(AES) so I went for ZipArchive Library I have Successfully Built the library using command make against the MAKEFILE by adding -m32 to Cflags as the following:
CFLAGS = -m32 -D _ZIP_SYSTEM_LINUX
then in the Terminal
make
that produced libzip.a
and that w...