note 104882 rejected from function.ziparchive-close by thiago

From: Date: Wed, 13 Jul 2011 20:39:37 +0000
Subject: note 104882 rejected from function.ziparchive-close by thiago
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-181487@lists.php.net to get a copy of this message
Note Submitter: adrynet at gmail dot com ---- If ZipArchive::close() returns FALSE and ZipArchive::getStatusString() says "Read error: No such file or directory" perhaps the problem is the new ZipArchive behaviour. In PHP 5.2.x, adding a file by ZipArchive::addFile() actually adds a file into the target zip file, so you can delete the added file from filesystem. If you have 5.2.x code, migrating to PHP 5.3.x, please pay attention to NOT delete the file to be added from filesystem until you call ZipArchive::close(). In other words, ZipArchive will create ZIP file only after you call the close() method. I hope it helps Adriano

« previous php.notes (#181487) next »