How to get name of zip file [php] [ziparchive]
Given a ZipArchive
, how is it possible to get the name of the file that is opened?
Call fsync on ZipArchive in PHP
Is there anyway to get access to underlying stream used by a ZipArchive
in php so that fsync
can be called on it?
downloaded zip with ZipArchive PHP which outputs strange strings
if (ob_get_length()) { ob_end_clean(); } $checkedValues = $img; $zipname = ‘file.zip’; $zip = new ZipArchive; // echo $zip.'<br>’; if ($zip->open($zipname, ZipArchive::CREATE) === TRUE) { echo $zipname.'<br>’; foreach ($checkedValues as $value) { if (file_exists($value)) { echo ‘Path: ‘ . htmlspecialchars($value) . ‘<br>’; echo ‘Path: ‘ . basename($value) . ‘<br>’; // $zip->addFile($value); $zip->addFromString(basename($value), file_get_contents($value)); } else { […]
Does ZipArchive::addFile() mess with hrtime()?
I have this loop: