Unzip/Extract files from archive with PHP (ZipArchive::extractTo)

PHP
Harish Kumar · · 211 Views

First, create new ZipArchive instance and then calling the open($filename, [$flags]) method. Now use extractTo($destination, $entries) method to extract zip file.

Parameters

  • destination: Location where to extract the files.

  • entries (optional): The entries to extract. It accepts either a single entry name or an array of names.

0

Please login or create new account to add your comment.

0 comments
You may also like: