CodeIgniter Forums

Full Version: Is there a CI function to UNZIP?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

[eluser]Eric Cope[/eluser]
I am trying to upload a zip file of photos. I hoped that there was a CI function to unzip those files. I can not find anything. Does anyone know who to do this?
Thanks!

El Forum

[eluser]schnoodles[/eluser]
Have a read in http://www.ellislab.com/codeigniter/user...s/zip.html although i have a feeling you can only ZIP and not UNZIP but i could be wrong.

El Forum

[eluser]Eric Cope[/eluser]
that was my impression, that it only zips...

El Forum

El Forum

[eluser]Eric Cope[/eluser]
I am trying to use that library, but with no results. Do you have any sample code using it to extract a file, removing all hierarchy in the zip file, and placing the unzipped files in a particular directory? Thanks

El Forum

[eluser]Eric Cope[/eluser]
php 4 and php 5 can have a zip library compiled into the binary. Luckily my server has this compiled in it. PHP 4 uses ZZIPlib, while PHP 5 uses Zlib.

I recommend using the PHP 5 version due to more features, but PHP 4 is all that is supported on my server as of today.

General CodeIgniter question: does CodeIgniter plan on supporting ZIP decode any time soon?