Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

ziparchive.extractto(3) [php man page]

ZIPARCHIVE.EXTRACTTO(3) 						 1						   ZIPARCHIVE.EXTRACTTO(3)

ZipArchive::extractTo - Extract the archive contents

SYNOPSIS
bool ZipArchive::extractTo (string $destination, [mixed $entries]) DESCRIPTION
Extract the complete archive or the given files to the specified destination. PARAMETERS
o $destination - Location where to extract the files. o $entries - The entries to extract. It accepts either a single entry name or an array of names. RETURN VALUES
Returns TRUE on success or FALSE on failure. EXAMPLES
Example #1 Extract all entries <?php $zip = new ZipArchive; if ($zip->open('test.zip') === TRUE) { $zip->extractTo('/my/destination/dir/'); $zip->close(); echo 'ok'; } else { echo 'failed'; } ?> Example #2 Extract two entries <?php $zip = new ZipArchive; $res = $zip->open('test_im.zip'); if ($res === TRUE) { $zip->extractTo('/my/destination/dir/', array('pear_item.gif', 'testfromfile.php')); $zip->close(); echo 'ok'; } else { echo 'failed'; } ?> PHP Documentation Group ZIPARCHIVE.EXTRACTTO(3)

Check Out this Related Man Page

ZIPARCHIVE(3)								 1							     ZIPARCHIVE(3)

The ZipArchive class

INTRODUCTION
A file archive, compressed with Zip. CLASS SYNOPSIS
ZipArchive ZipArchive Properties o int$status o int$statusSys o int$numFiles o string$filename o string$comment Methods o bool ZipArchive::addEmptyDir (string $dirname) o bool ZipArchive::addFile NULL (string $filename, [string $localname], [int $start], [int $length]) o bool ZipArchive::addFromString (string $localname, string $contents) o bool ZipArchive::addGlob (string $pattern, [int $flags], [array $options = array()]) o bool ZipArchive::addPattern (string $pattern, [string $path = "."], [array $options = array()]) o bool ZipArchive::close (void ) o bool ZipArchive::deleteIndex (int $index) o bool ZipArchive::deleteName (string $name) o bool ZipArchive::extractTo (string $destination, [mixed $entries]) o string ZipArchive::getArchiveComment ([int $flags]) o string ZipArchive::getCommentIndex (int $index, [int $flags]) o string ZipArchive::getCommentName (string $name, [int $flags]) o bool ZipArchive::GetExternalAttributesIndex (int $index, int &$opsys, int &$attr, [int $flags]) o bool ZipArchive::getExternalAttributesName (string $name, int &$opsys, int &$attr, [int $flags]) o string ZipArchive::getFromIndex (int $index, [int $length], [int $flags]) o string ZipArchive::getFromName (string $name, [int $length], [int $flags]) o string ZipArchive::getNameIndex (int $index, [int $flags]) o string ZipArchive::getStatusString (void ) o resource ZipArchive::getStream (string $name) o int ZipArchive::locateName (string $name, [int $flags]) o mixed ZipArchive::open (string $filename, [int $flags]) o bool ZipArchive::renameIndex (int $index, string $newname) o bool ZipArchive::renameName (string $name, string $newname) o bool ZipArchive::setArchiveComment (string $comment) o bool ZipArchive::setCommentIndex (int $index, string $comment) o bool ZipArchive::setCommentName (string $name, string $comment) o bool ZipArchive::setExternalAttributesIndex (int $index, int $opsys, int $attr, [int $flags]) o bool ZipArchive::setExternalAttributesName (string $name, int $opsys, int $attr, [int $flags]) o public bool ZipArchive::setPassword (string $password) o array ZipArchive::statIndex (int $index, [int $flags]) o array ZipArchive::statName (string $name, [int $flags]) o bool ZipArchive::unchangeAll (void ) o bool ZipArchive::unchangeArchive (void ) o bool ZipArchive::unchangeIndex (int $index) o bool ZipArchive::unchangeName (string $name) PROPERTIES
o $status -Status of the Zip Archive o $statusSys -System status of the Zip Archive o $numFiles -Number of files in archive o $filename -File name in the file system o $comment -Comment for the archive PHP Documentation Group ZIPARCHIVE(3)
Man Page