Downloading a Zip : file is corrupted Downloading a Zip : file is corrupted
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Downloading a Zip : file is corrupted

Started by nerovik, January 03, 2008, 08:57:16 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

nerovik

Good evening,

I have spent a lot of time with Frantz (french forum) to find out a solution. I have also looked through the entire forum for a solution. I feel desperate.
My problem is the following : I select one picture and click Add to Favorites. Then I click on My favorites and click dowload as Zip file. The pictures.zip cannot be uncompressed. 7-zip (or whatever) says that the header file is corrupted.

It works perfectly on a public website (http://liminaires.free.fr) but it does not work at home nor at my office.

My local Web server is Wamp 2.0 - PHP Version 5.2.5
Windows Vista
IE7 or Firefox (latest versions)
Php-zip.dll is activated.
Phpinfo is attached

We have already compared our configurations with Frantz (French forum). I can reproduce this problem on several different PCs  (windows XP) at my office.

I cannot find out how I can solve this problem and it is very (very) urgent for me to solve it. The aim is to present a photo gallery at my office (Xampp server - virtual machine).
I can only give access to my PC at home. Let me know if you can help me. Thanks in advance.



Nibbler

Post an example of the corrupted zip file.

nerovik

Please find enclosed pictures.zip.
Thanks for your prompt reply.

Nibbler

There's some strange characters at the start of the file. It's not whitespace. Perhaps a BOM or something. Does it work if you switch to english or change theme?

nerovik

That's right, the header of the zip file is corrupted.
It does not work either in english.
Just let you know that I have reinstalled (fresh install) coppermine => same problem
I have modified chaoticsoul template but same problem occur with classic theme.
PYAP (from the french forum) told me that it should come from my server (Wamp). But I also tried with Xampp (another server).

Nibbler

Try changing


$zip->download_file();


to


ob_end_clean();
$zip->download_file();


in include/archive.php

nerovik

$zip->download_file(); does not exist (?)

Nibbler


nerovik

You are fantastic! Thank you so much. Can you explain to me quickly ?

Nibbler

It makes sure nothing is sent to the browser before the zip file begins.

Joachim Müller

@Nibbler: should this go into the core as a precaution for others with similar issues?

Joachim Müller

@Nibbler: ignore the above question - I just performed a checkout and noticed that you already added your code to the core both of cpg1.4.x as well as cpg1.5.x. Should have done this before posting my silly question, sorry.

nerovik


Problem reopened:
It works on Windows Vista (IE7/Firefox) but it still does not work on Windows XP (IE6).
Thanks for your help!

Joachim Müller

Merged you new thread with the existing one. Don't double post; there is a reason why solved threads don't get locked immediately: you can still reply to them if it seems like a solved issue needs to be looked into further.

I find it hard to believe though that this should be related to the client OS: after all, the zip file creation happens on the server, not on the client: how could a client OS possibly interfere then? Anyway, tested this on Windows XP Professional German SP2 with Firefox 2.0.0.11 and IE7.0.5730.11 on your site - both work as expected, the zip files are perfectly OK.

nerovik

I confirm  : Internet Explorer 6 seems to be my source of annoyance!

aldog

I was having this same problem and I did what nibbler suggested. and now I get this problem

!   C:\Documents and Settings\alans\Desktop\pictures.zip: The archive is either in unknown format or damaged


any suggestions?

Sami

- Attach that file to this thread
- Post a link to your gallery
‍I don't answer to PM with support question
Please post your issue to related board

aldog


Sami

Zip File is fine !!!
Also I downloaded same file my self and it's fine too!
‍I don't answer to PM with support question
Please post your issue to related board

aldog

Ya I guess you're right, that one does work. I just downloaded another one with 6 files and got a corrupted error again.


here it is http://www.ad6storieshigh.com/uberdownloads/personal/pictures(3).zip
500kb limit on the attachments. hope that helps.