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

search for in the

ZipArchive::setCommentName> <ZipArchive::setArchiveComment
Last updated: Fri, 30 Oct 2009

view this page in

ZipArchive::setCommentIndex

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

ZipArchive::setCommentIndexSetzt einen Eintragskommentar, der via Eintragsindex bestimmt wird

Beschreibung

mixed ZipArchive::setCommentIndex ( int $index , string $comment )

Setzt einen Eintragskommentar, der via Eintragsindex bestimmt wird.

Parameter-Liste

index

Index des Eintrags.

comment

Der Inhalt des Kommentars.

Rückgabewerte

Gibt bei Erfolg TRUE zurück, im Fehlerfall FALSE.

Beispiele

Beispiel #1 Ein Archiv öffnen und für einen Eintrag einen Kommentar hinzufügen

<?php
$zip 
= new ZipArchive;
$res $zip->open('test.zip');
if (
$res === TRUE) {
    
$zip->setCommentIndex(2'Neuer Eintragskommentar');
    
$zip->close();
    echo 
'ok';
} else {
    echo 
'Fehler';
}
?>


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

ZipArchive::setCommentName> <ZipArchive::setArchiveComment
Last updated: Fri, 30 Oct 2009
 
 
show source | credits | stats | sitemap | contact | advertising | mirror sites