note 101605 added to function.ziparchive-addfile
| From: | johnfactorial at osu1 dot php dot net | Date: | Wed, 29 Dec 2010 20:57:22 +0000 |
| Subject: | note 101605 added to function.ziparchive-addfile | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-175317@lists.php.net to get a copy of this message | ||
Beware: calling $zip->addFile() on a file that doesn't exist will succeed and return TRUE,
delaying the failure until you make the final $zip->close() call, which will return FALSE and
potentially leave you scratching your head.
If you're adding multiple files to a zip and your $zip->close() call is returning FALSE,
ensure that all the files you added actually exist.
It's also a good idea to check each file with file_exists() or is_readable() before calling
$zip->addFile() on it.
----
Server IP: 208.69.120.55
Probable Submitter: 64.238.108.50
----
Manual Page -- http://www.php.net/manual/en/function.ziparchive-addfile.php
Edit -- https://master.php.net/note/edit/101605
Del: integrated -- https://master.php.net/note/delete/101605/integrated
Del: useless -- https://master.php.net/note/delete/101605/useless
Del: bad code -- https://master.php.net/note/delete/101605/bad+code
Del: spam -- https://master.php.net/note/delete/101605/spam
Del: non-english -- https://master.php.net/note/delete/101605/non-english
Del: in docs -- https://master.php.net/note/delete/101605/in+docs
Del: other reasons-- https://master.php.net/note/delete/101605
Reject -- https://master.php.net/note/reject/101605
Search -- https://master.php.net/manage/user-notes.php