Correct is:
<?php
file_put_contents('output.gz', gzencode( file_get_contents('input.file'),9));
?>
![]() |
|
||||||||||
|
gzencodeОписаниеstring gzencode ( string data [, int level [, int encoding_mode]] )
Возвращает сжатую версию данных Для подробностей по формату GZIP, см. GZIP file format specification 4.3 (RFC 1952). Список параметров
ПримерыВозвращаемые данные будут содержать соответствующие заголовки и структуры данных как в обычном .gz-файле, например: gzencode
cbrunon at free dot fr
03-Aug-2006 06:52
Correct is:
Aaron G.
06-Aug-2004 06:29
<?php
tychay at alumni dot caltech dot edu
03-Apr-2002 02:53
The 10 byte string in gzencode is the standard gzip header. The first two bytes (1f 8b) define the return as a gzip file, the third byte (08) means that the body is compressed using the "deflate" algorithm. The rest is padding (00)'s.
henryk at ploetzli dot ch 14-Feb-2002 06:28
Well, I was looking for a gzdecode too and didn't consider the temporary file example above to be very elegant. |
| © 2007 info@grandviewstudio.com |
|
Deprecated: Function set_magic_quotes_runtime() is deprecated in /home/sites/grandviewstudiocom/www/65f67d67a94ad980786580ae69e11c07/sape.php on line 324 Deprecated: Function set_magic_quotes_runtime() is deprecated in /home/sites/grandviewstudiocom/www/65f67d67a94ad980786580ae69e11c07/sape.php on line 330 Z058440144362 Z348613067571 |