public static function createArchive($fileSystem, $name = "weborb.codegen.zip", $path = WebOrb, $libPath = "") { set_time_limit(0); $fileList = ""; if ($path != WebOrb) { $weborbInstallDir = substr(WebOrb, 0, strlen(WebOrb) - 7); self::createPath($weborbInstallDir, $path); self::$path = $weborbInstallDir . $path . DIRECTORY_SEPARATOR; if ($libPath != "") { $libPath = $weborbInstallDir . $libPath; } } else { self::$path = $path; } if (file_exists(self::$path . $name)) { unlink(self::$path . $name); } $archive = new PclZip(self::$path . $name); self::createFilesAndFolders($fileSystem->Result->Items, $archive, "TempCodegen", $fileList); if ($libPath != "") { self::addLib($libPath, $archive); } }