Class Archive

Methods summary

protected string
# uploadZipToTemp( string $file )

Moves an uploaded file to the tmp directory.

protected string
# unzip( string $directory )

Unzips a file at a directory level by concatenating ".zip" onto the end of it.

unzip("/path/to/files/themes/mytheme") // will unzip ""


protected string
# getArchiveDirectory( string $dir )

Returns either the directory (if the archive itself contains files at the first level) or the subdirectory if, like many archiving programs, we the zip archive is a directory, THEN a list of files.

protected string
# install( string $file, boolean $inplace = false )

Installs a zip file from the passed directory.

Properties summary

protected string $targetDirectory

The directory where this archive will be unzipped.

# "/dev/null"
protected Concrete\Core\File\Service\File $f

File helper instance.