php-src/ext/zip/examples/addpattern.php
Remi Collet 5dc37b3510 Sync ext/zip with pecl/zip version 1.3.2
- update libzip to version 1.11.1. We don't use any private symbol anymore
- new method ZipArchive::setPassword($password)
- add --with-libzip option to build with system libzip
2013-11-04 13:23:36 +01:00

14 lines
313 B
PHP

<?php
$z = new ZipArchive;
$z->open('a.zip', ZIPARCHIVE::CREATE);
/* or 'remove_all_path' => 0*/
$options = array('remove_path' => '/home/pierre/cvs/gd/libgd/tests',
'add_path' => 'images/',
);
$found = $z->addPattern("/(\.png)$/i", "/home/pierre/cvs/gd/libgd/tests", $options);
var_dump($found);
$z->close();