📜  php 压缩 csv 文件 - PHP 代码示例

📅  最后修改于: 2022-03-11 14:54:49.449000             🧑  作者: Mango

代码示例1
$zip = new ZipArchive();
$filename = "./test1.zip";

if ($zip->open($filename, ZipArchive::CREATE)!==TRUE) {
    exit("cannot open <$filename>\n");
}

$zip->addFile($thisdir . "/file1.csv");
$zip->close();