|  | 
  Josué - 2008-02-14 01:12:00When I try to open the zip file all is fine on Linux and Windows but not in Mac Os. I download de createzipFileMac.php 
 That's my code of a simple zip that i try to buid :
 
 <?
 include_once("CreateZipFileMac.zip.php");
 $zip = new CreateZip;
 $zip->addDirectory("something/");
 header("Pragma: cache");
 header("Expires: 0");
 header("Cache-Control: private",false);
 header("Content-Type: application/octet-stream");
 header("Content-Disposition: attachment; filename=\"dothat.zip\";" );
 header("Content-Transfer-Encoding: 8bit");
 echo $zip->getZippedfile();
 ?>
 
 
  Er. Rochak Chauhan - 2008-02-14 07:03:48 - In reply to message 1 from JosuéI guess there is no head to specify header in the code... The headers are mentioned in the class/method it self
  Josué - 2008-02-14 07:48:18 - In reply to message 2 from Er. Rochak ChauhanWell I use the Header of the class , and the result is the same. The file can be opened on the Mac os :/ ...
  Daniel O - 2008-02-14 16:30:22 - In reply to message 1 from JosuéI am having the same difficulty. When I download on Windows it works fine. Then I move the file to a mac and it gives me a decompression error.
 However, if I use StuffIt, the file opens perfectly! I also tried downloading it directly from the site and I get the same errors. This has nothing to do with the PHP headers.
 
 Is the ZIP file encrypted at all? Is there some HEX that needs to be changed. I tried analyzing the HEX from a Mac created file and the PHP created file and there are a lot of differences, but none of them seem to be significant. Any ideas? I need this to open in the default Archive Utility on a mac.
 
 Thank you for your help!
  Daniel O - 2008-02-18 14:22:57 - In reply to message 1 from JosuéDoes anyone have any ideas about this? I have tried it on Tiger and Leopard with the same results.
  Andi Keller - 2008-03-10 09:43:31 - In reply to message 5 from Daniel OHi Daniel,I've got the same problems. Did you find a solution for this?
 
 regards
 Andi
  MJ - 2008-03-22 02:01:04 - In reply to message 1 from JosuéSame problem here.
 Works with Stuffit Expander but not with Mac OS X's ZIP-Utility. Otherwise great!
  licinio - 2008-06-30 17:48:24 - In reply to message 7 from MJSame problem for me,it works correctly for windows/linux, but it doesn´t work for mac
 
 I´ve noticed that
 CreateZipFileMac and CreateZipFile files are the same.
 Maybe it´s a mistake?
 
 thanks
  JamesCovey - 2009-04-20 05:14:51 - In reply to message 8 from licinioI'm having the same problem, and the mac file is the same, I compared them back to back.
  David Klanac - 2009-06-26 01:35:32 - In reply to message 8 from licinioYep.  Windows and the shell 'unzip' binary in linux and mac osx is happy with the generated zip files.  It's definitely a problem with the StuffIt Expander that is used by default on Leopard clients to extract zip files.  Is there anything that can be done to fix this problem?
 Here are my console messages in Leopard when trying to use the default extractor:
 
 6/25/09 9:34:33 PM Archive Utility[2193] NSExceptionHandler has recorded the following exception:
 NSFileHandleOperationException -- *** -[NSConcreteFileHandle writeData:]: Broken pipe
 Stack trace:  0xa819a  0x91120e3b  0x906ffe8b  0x906ffeca  0x9543eed3  0x953c24db  0x1a242  0x14cd7  0x95329e0d  0x953299b4  0x90435155  0x90435012
 
 
 6/25/09 9:34:33 PM Archive Utility[2193] failed to write to /usr/bin/ditto
 
 
 6/25/09 9:34:33 PM [0x0-0xce0ce].com.apple.archiveutility[2193] ditto: Couldn't read PKZip signature
 |