(PHP 3, PHP 4 )

gzread -- Binary-safe gz-file read


string gzread ( resource zp, int length)

gzread() reads up to length bytes from the gz-file pointer referenced by zp. Reading stops when length (uncompressed) bytes have been read or EOF is reached, whichever comes first.

例子 1. gzread() example

// get contents of a gz-file into a string
$filename = "/usr/local/something.txt.gz";
$zd = gzopen($filename, "r");
$contents = gzread($zd, 10000);

See also gzwrite(), gzopen(), gzgets(), gzgetss(), gzfile(), and gzpassthru().

虎的笑话 虎的成语 虎的歇后语