downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

ZipArchive::getFromIndex> <ZipArchive::getCommentIndex
Last updated: Fri, 13 Nov 2009

view this page in

ZipArchive::getCommentName

(PHP 5 >= 5.2.0, PECL zip >= 1.4.0)

ZipArchive::getCommentNameエントリ名を使用して、エントリのコメントを返す

説明

string ZipArchive::getCommentName ( string $name [, int $flags ] )

エントリ名を使用して、エントリのコメントを返します。

パラメータ

name

エントリの名前。

flags

ZIPARCHIVE::FL_UNCHANGED を指定すると、 元の変化していないコメントが返されます。

返り値

成功した場合にコメント、失敗した場合に FALSE を返します。

例1 エントリのコメントの出力

<?php
$zip 
= new ZipArchive;
$res $zip->open('test1.zip');
if (
$res === TRUE) {
    
var_dump($zip->getCommentName('test/entry1.txt'));
} else {
    echo 
'失敗、コード:' $res;
}
?>


add a note add a note User Contributed Notes
ZipArchive::getCommentName
There are no user contributed notes for this page.

ZipArchive::getFromIndex> <ZipArchive::getCommentIndex
Last updated: Fri, 13 Nov 2009
 
 
show source | credits | sitemap | contact | advertising | mirror sites