php ziparchive类,PHP Zip ZipArchive 类_编程学问网

本文详细介绍了PHP ZipArchive类的各种方法,包括添加文件、字符串、glob模式和正则表达式匹配的文件,关闭、计数、删除、获取元数据、读取内容、重命名、设置属性等操作。掌握这些功能有助于高效管理ZIP档案。
摘要由CSDN通过智能技术生成

ZipArchive::addFile — Adds a file to a ZIP archive from the given path

ZipArchive::addFromString — Add a file to a ZIP archive using its contents

ZipArchive::addGlob — Add files from a directory by glob pattern

ZipArchive::addPattern — Add files from a directory by PCRE pattern

ZipArchive::close — Close the active archive (opened or newly created)

ZipArchive::count — Counts the number of files in the achive

ZipArchive::deleteIndex — Delete an entry in the archive using its index

ZipArchive::deleteName — Delete an entry in the archive using its name

ZipArchive::getArchiveComment — Returns the Zip archive comment

ZipArchive::getCommentIndex — Returns the comment of an entry using the entry index

ZipArchive::getCommentName — Returns the comment of an entry using the entry name

ZipArchive::getExternalAttributesIndex — Retrieve the external attributes of an entry defined by its index

ZipArchive::getExternalAttributesName — Retrieve the external attributes of an entry defined by its name

ZipArchive::getFromIndex — Returns the entry contents using its index

ZipArchive::getFromName — Returns the entry contents using its name

ZipArchive::getNameIndex — Returns the name of an entry using its index

ZipArchive::getStatusString — Returns the status error message, system and/or zip messages

ZipArchive::getStream — Get a file handler to the entry defined by its name (read only)

ZipArchive::locateName — Returns the index of the entry in the archive

ZipArchive::open — Open a ZIP file archive

ZipArchive::renameIndex — Renames an entry defined by its index

ZipArchive::renameName — Renames an entry defined by its name

ZipArchive::setArchiveComment — Set the comment of a ZIP archive

ZipArchive::setCommentIndex — Set the comment of an entry defined by its index

ZipArchive::setCommentName — Set the comment of an entry defined by its name

ZipArchive::setCompressionIndex — Set the compression method of an entry defined by its index

ZipArchive::setCompressionName — Set the compression method of an entry defined by its name

ZipArchive::setEncryptionIndex — Set the encryption method of an entry defined by its index

ZipArchive::setEncryptionName — Set the encryption method of an entry defined by its name

ZipArchive::setExternalAttributesIndex — Set the external attributes of an entry defined by its index

ZipArchive::setExternalAttributesName — Set the external attributes of an entry defined by its name

ZipArchive::setPassword — Set the password for the active archive

ZipArchive::statIndex — Get the details of an entry defined by its index

ZipArchive::statName — Get the details of an entry defined by its name

ZipArchive::unchangeAll — Undo all changes done in the archive

ZipArchive::unchangeArchive — Revert all global changes done in the archive

ZipArchive::unchangeIndex — Revert all changes done to an entry at the given index

ZipArchive::unchangeName — Revert all changes done to an entry with the given name

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值