SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Enthusiast sportstoto3368's Avatar
    Join Date
    Apr 2004
    Location
    World
    Posts
    64
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    ZipArchive not working properly...

    Hi all,

    Problem I am facing is extractTo( cannot run properly.

    $destination= "D:/inetpub/vhosts/test8.com/httpdocs/hohoho/";
    $MasterLocation= "C:/HostedSolution//master.zip";

    $zip = new ZipArchive;
    if ($zip->open($MasterLocation) === TRUE)
    {
    $zip->extractTo($destination); ////error occur here
    $zip->close();


    Warning: ZipArchive::extractTo() [function.ZipArchive-extractTo]: File exists in D:\inetpub\vhosts\domainname.com\httpdocs\r\api\fileAPI22-MY.php on line 27

    it keep on saying file exists

    hohoho folder is confirmed empty. But i dunno why the php keep on saying file exists....

    line 27 is the extractTo($destination) line

    Help...

    is it due to php version? or php extract won't work properly in windows iis server, or need to set something in php configuration file?

  2. #2
    I Never Give Up roosevelt's Avatar
    Join Date
    May 2005
    Posts
    515
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    I am not sure if it's going to work but doesn't hurt trying. Open up the folder properties for the folder 'hohoho' and remove the Read-Only tick off it.

    I would also take a look at IIS Logs and PHP logs to further debug the issue.

    Cheers!


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •