Results 1 to 4 of 4

Thread: Class zipArchive not found

  1. #1
    Registered Member
    Join Date
    Jan 2004

    Default Class zipArchive not found

    We are trying to unzip a file. We are running php 5.2.0 with zip on a WHM 10.8.0 cPanel 10.9.0-R57 CentOS 4.4 i686 - WHM X v3.1.0

    After upgrading to 5.2.0, we
    ./configure --enable-zip
    make install
    no errors, but in the phpinfo it does not show enable zip and when we try to open the zip file we receive the error:
    Class ZipArchive not found

    Any help would be greatly appreciated.

    Thanks for all your help,

  2. #2
    Registered Member Rafaelfpviana's Avatar
    Join Date
    Mar 2004


    hello there,

    this week I had a custumer with the same problem and what I learned was that eventhough says that PHP 5.2 comes with the ZIP library as bundle for some reason PHP on Cpanel servers don't get compiled with it.

    This isn't new, the compile Apache has the Zip option but I never saw it working, and I've tested on 10 different servers.

    What I suggest is that you compile de PECL availble here

    well, good luck.

  3. #3
    Registered Member Rafaelfpviana's Avatar
    Join Date
    Mar 2004


    ok, to install the ZIP PECL library do this:

    first create a phpinfo file to get necessary informations, like this:

    PHP Code:
    save it as phpinfo.php any where in the server, but remember, you are going to need to see this file on a browser.

    open the browser and open that phpinfo file that you've just created and search for these 2 values:

    Configuration File (php.ini) Path



    login into your server as root and type this:

    cd /usr/src/
    tar -xzf zip-1.8.0.tgz
    rm -f zip-1.8.0.tgz
    cd ./zip-1.8.0
    make install
    when you type make install something like this will be written on the screen:

    Installing shared extensions:     /usr/local/lib/php/extensions/no-debug-non-zts-20060613/
    write that down somewhere, copy and paste it on a notepad.

    what you just did was compile the library, now you need to edit php.ini file to turn the extension on:

    vi you_php_ini_path_here
    type / to search and search for enable_dl and make sure this is set to on

    type / to search and search for extension_dir and paste the thing I told you to paste on the notepad, so it looks something like this:

    extension_dir   = "/usr/local/lib/php/extensions/no-debug-non-zts-20050922/";
    now right bellow that add this

    now just restart apache and look at the phpinfo file.

    any questions, just ask
    Last edited by Rafaelfpviana; 11-21-2006 at 07:44 AM.

  4. #4
    Registered User
    Join Date
    Nov 2006


    i did everything that you said, and it seemed to work perfectly. I restarted apache and looked at my phpinfo file. Now how would i install the --enable-zip for php. I can't seem to find the php directory that has the configure command. I've done a find / -name 'configure' and there are a few for other programs, but nothing for php. Yet php is on the server and working, because my phpinfo page works.

    The extension_dir is correct on the phpinfo file too.
    Last edited by domflann; 11-24-2006 at 05:14 PM.

Similar Threads

  1. Class Pdo Not Found!
    By roasthawg in forum General Discussion
    Replies: 1
    Last Post: 11-14-2013, 03:57 PM
  2. Fatal error: Class 'PDO' not found in
    By crazyaboutlinux in forum General Discussion
    Replies: 7
    Last Post: 05-07-2009, 03:24 AM
  3. Fatal error: Class 'Zend_Loader' not found
    By d0840001 in forum Discusión en Español
    Replies: 1
    Last Post: 06-05-2008, 04:07 AM
  4. Fatal error: Class 'Zend_Loader' not found
    By d0840001 in forum General Discussion
    Replies: 0
    Last Post: 06-01-2008, 12:22 PM