On Apr 8, 2015, at 3:04 PM, Christoph Becker wrote:
Jeffry Killen wrote:
My question is: Where is the test.zip archive file located? (/tmp,
maybe?)
I would expect it to be in the same dir as the processing script,
but I
don't see anything in the dir
by the name of test.zip.
I might be completely wrong, but I believe that the actual test.zip is
only created if everything worked out fine (including that the zip
won't
be empty). So unless you're getting "good to go: ...", there won't
be a
zip file.
If everything works well, the file is supposed to be created in the
current working directory, i.e. the usually the directory of the
requested script.
Thank you for the inro:
As it turns out, the cwd of the script did not have adequate write
permissions set.
Once I corrected that problem I got the test.zip file to show up.
But I am wondering why I did not get the error code:
ZIPARCHIVE::ER_OPEN
Can't open file... if write permissions where wrong?
Since posting this query, I got a zip file created with an included
directory
and downloaded and uncompressed it successfully.
I ran across user comments on the php.net site for ZipArchive claiming
that
addEmptyDir was remove or disabled, and in fact I couldn't get it to
work.
I was able to include a dir in the zip file by using addFile and
naming the file
with a containing dir: "storage/toZip.txt"
I also discovered that calling download code from an async get request
wouldn't
work. I just got the contents of the zip file returned to the origin
page (as I coded it
in the original message).
I got it to work with sync form submission.
Thanks for time and attention:
JK
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php