FileFetcherUploadZip

Extends \LimeSurvey\ExtensionInstaller\FileFetcher

Extension file fetcher for upload ZIP file.

Must work for all extension types: plugins, theme, question theme, etc.

since 2018-09-25
author

Olle Haerstedt

package

Default

Methods

Abort procedure, remove temporary files.

abort() : void
inherited abstract

checkFileSizeError

checkFileSizeError() : void
todo

Duplicate from themes.php.

Throws
\LimeSurvey\ExtensionInstaller\Exception

Check if uploaded zip file is a zip bomb.

checkZipBom() : void

Set user session tempdir to null.

clearTmpdir() : void

extractZipFile

extractZipFile(string $tempdir) : void

Arguments

$tempdir

string

Move files from source to tmp/ folder.

fetch() : void
inherited abstract

getConfig

getConfig() : \LimeSurvey\ExtensionInstaller\ExtensionConfig
inherited abstract
Throws
\LimeSurvey\ExtensionInstaller\Exception

if config cannot be parsed.

Response

\LimeSurvey\ExtensionInstaller\ExtensionConfig

Get tmp tempdir for extension to unzip in.

getTempdir() : string

Response

string

Move files from tmp/ folder to final destination.

move(string $destdir) : boolean
inherited abstract

Arguments

$destdir

string

Response

boolean

Set source for this file fetcher.

setSource(string $source) : void
inherited abstract

Can be ZIP file name, git repo URL, folder name, etc.

Arguments

$source

string

setUnzipFilter

setUnzipFilter(string $filterName) : void

Arguments

$filterName

string

Properties

Filter to apply to unzipping.

filterName : string
var

Type(s)

string