PhpConcept

Developers Tools

  • Increase font size
  • Default font size
  • Decrease font size
Home PclZip User Guide

PclZip User Guide - PCLZIP_OPT_REMOVE_PATH

Print PDF

PCLZIP_OPT_REMOVE_PATH

This arguments gives the ability to suppress a part or all the path of the files (or directories) when they are extracted or archived. This will allow to archive file '/usr/local/user/test/file.txt' like a file with name 'test/file.txt', or to extract file stored with name 'folder/data/file.txt' as file 'data/file.txt' on the filesystem.
The value is a single directory path string.

      $list $archive->add("/usr/local/user/test/file.txt",
                            
PCLZIP_OPT_REMOVE_PATH"/usr/local/user");

This argument can be used with 'create()', 'add()', 'extract()' and 'extractByIndex()' methods.
Notice that this argument is ignored when argument PCLZIP_OPT_REMOVE_ALL_PATH is used in the same method call.

 

[Optional Arguments List]

 

Last Updated on Thursday, 17 December 2009 23:20