:::

9-6 zip.php

<?php
include_once "header.php";
include_once 'class/pclzip.lib.php';

$bak_dir      = XOOPS_ROOT_PATH . "/uploads/snews";
$remove_path  = XOOPS_ROOT_PATH . "/uploads/";
$bak_file     = XOOPS_ROOT_PATH . "/uploads/bak_" . date("YmdHi") . ".zip";
$bak_file_url = XOOPS_URL . "/uploads/bak_" . date("YmdHi") . ".zip";

$zipfile      = new PclZip($bak_file);
$zip_list     = $zipfile->create($bak_dir, PCLZIP_OPT_REMOVE_PATH, $remove_path);
if ($zip_list == 0) {
    die("Error : " . $zipfile->errorInfo(true));
} else {
    header("location: {$bak_file_url}");
    exit;
}

 


:::

搜尋

QR Code 區塊

https%3A%2F%2Fmail.tad0616.cp27.secserverpros.com%2Fmodules%2Ftad_book3%2Fpage.php%3Ftbdsn%3D1504%26tbsn%3D44

書籍目錄

展開 | 闔起

線上使用者

361人線上 (144人在瀏覽線上書籍)

會員: 0

訪客: 361

更多…