|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2014-04-02 08:02 UTC] ab@php.net
-Status: Open
+Status: Feedback
[2014-04-02 08:02 UTC] ab@php.net
[2014-04-02 20:35 UTC] sailormax at inbox dot lv
-Status: Feedback
+Status: Open
[2014-04-02 20:35 UTC] sailormax at inbox dot lv
[2015-04-16 12:52 UTC] cmb@php.net
-Package: zip
+Package: Zip Related
[2021-05-31 14:42 UTC] cmb@php.net
-Status: Open
+Status: Feedback
-Assigned To:
+Assigned To: cmb
[2021-05-31 14:42 UTC] cmb@php.net
[2021-06-13 04:22 UTC] php-bugs at lists dot php dot net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 13:00:01 2025 UTC |
Description: ------------ Looks like $ZipArchive->addFile() don't see source file, if it placed near the executed script inside PHAR. Steps: 1. create phar-file with: - embed.xml with any data; - index.php with: ~~~~ $objZip = new ZipArchive(); $objZip->open("test.zip", ZIPARCHIVE::CREATE); $objZip->addFile(dirname(__FILE__) . '/embed.xml', 'test/embed.xml'); $objZip->close(); ~~~~ Exp: test.zip with embed.xml Act: test.zip without embed.xml . addFile() return false; Test script: --------------- $objZip = new ZipArchive(); $objZip->open("test.zip", ZIPARCHIVE::CREATE); $objZip->addFile(dirname(__FILE__) . '/embed.xml', 'test/embed.xml'); $objZip->close(); Expected result: ---------------- test.zip with embed.xml Actual result: -------------- test.zip without embed.xml . addFile() return false;