diff --git a/files/index.php b/files/index.php index 53332d4d81e..437d36fe613 100644 --- a/files/index.php +++ b/files/index.php @@ -366,7 +366,7 @@ foreach ($USER->filelist as $file) { $files[] = "$basedir/$file"; } - include_once('../lib/pclzip/pclzip.lib.php'); + include_once("$CFG->libdir/pclzip/pclzip.lib.php"); $archive = new PclZip("$basedir/$wdir/$name"); if (($list = $archive->create($files,'',"$basedir/$wdir/")) == 0) { error($archive->errorInfo(true)); @@ -432,7 +432,7 @@ $file = basename($file); if (empty($CFG->unzip)) { // Use built-in php-based unzip function - include_once('../lib/pclzip/pclzip.lib.php'); + include_once("$CFG->libdir/pclzip/pclzip.lib.php"); $archive = new PclZip("$basedir/$wdir/$file"); if (!$list = $archive->extract("$basedir/$wdir")) { error($archive->errorInfo(true)); @@ -493,7 +493,7 @@ echo "
$strlistfiles:
"; $file = basename($file); - include_once('../lib/pclzip/pclzip.lib.php'); + include_once("$CFG->libdir/pclzip/pclzip.lib.php"); $archive = new PclZip("$basedir/$wdir/$file"); if (!$list = $archive->listContent("$basedir/$wdir")) { notify($archive->errorInfo(true));