I couldn't find any how-to example for getting the filenames, so I made an easy one.
Here's an example how to list all filenames from a zip-archive:
<?php
$zip = new ZipArchive;
if ($zip->open('items.zip'))
{
for($i = 0; $i < $zip->numFiles; $i++)
{
echo 'Filename: ' . $zip->getNameIndex($i) . '<br />';
}
}
else
{
echo 'Error reading zip-archive!';
}
?>
Hope it helps.