/** * @see \wcf\action\IAction::execute() */ public function execute() { parent::execute(); $filename = BackupHandler::getInstance()->getExportArchive(); $this->executed(); header('Content-Type: application/x-gzip; charset=utf8'); header('Content-Disposition: attachment; filename="CMS-Export.tar.gz"'); readfile($filename); @unlink($filename); }
/** * @see \wcf\form\IForm::save() */ public function save() { parent::save(); //perform import BackupHandler::getInstance()->handleImport($this->backup); $this->saved(); WCF::getTPL()->assign('success', true); }