Hello,
Did you mean gzip? If so, you can find a good explanation here:
http://ca2.php.net/manual/en/ref.zlib.php
It should be straightforward, but note that you need to compile PHP with zlib library.
As for pkzip, officially, PHP supports reading only, it seems like:
http://ca2.php.net/manual/en/ref.zip.php
But pay attention to the comments on the above page - someone offers a library to create one, too. BUT I have never even tried reading pkzip files with PHP, so I cannot comment further nor be responsible for whatever you do with it.
Hope this helps.