Jesus · Bible · HTML · CSS · JS · PHP · SVG · Applications

gzclose

Description

The gzclose of zlib for PHP closes an open gz-file pointer.

Syntax

gzclose(
    resource $stream
): bool

Parameters

stream

The gz-file pointer. It must be valid, and must point to a file successfully opened by gzopen().

Return

Returns true on success or false on failure.

Examples

1 · stream

<?

$filename = $_SERVER["DOCUMENT_ROOT"] . "/assets/gz/1.gz";
$mode = "r";

$stream = gzopen($filename, $mode);

    if($stream === false)
    {
        die("gzopen");
    }

$return = gzclose($stream);

var_export($return);

?>
true
HomeMenu