If the stream is readable, compress the data in the stream using deflate compression. The uncompressed stream is then closed, and the compressed stream then becomes the wrapped stream.
string $filter Compression filter:
bool Returns TRUE on success or FALSE on failure
public function compress($filter = 'zlib.deflate');