Everything is working except the actual file download. I can go all the way through the checkout and paypal process (using sandbox) but when I click the "Continue" link to download the ZIP file I get an error saying the file cannot be downloaded. Anybody have any ideas? Are there any permissions I need to look into?
Posts: 19
Just to add a little more info, apparently the ZIP file is being created because I see a ZIP file in the /g2data/tmp that is named after the order number. And when I FTP it and open it up, it does indeed have the JPG file inside. So, I can say for sure the ZIP file is being created in a temp location but something is failing after that.
Posts: 19
I confirmed that each time I click the button to download the ZIP file, a ZIP file gets created in the /g2data/tmp directory. For example: 105.zip However, when I click the Continue... link I get an error that the file cannot be downloaded. After getting this error I immediately check the tmp directory and the ZIP file is gone. Any ideas?
Posts: 4342
Where's the technical info you are asked to provide when opening a new thread? What's in your server error log?
Posts: 19
Sorry, here's the system info...
As for errors, there's nothing in the recent event log in gallery other than failed email attemps with my temporary testing account with sandbox. As for errors on my web hosting logs, I haven't seen anything in the error log via my web hosting control panel. I do see plenty of things in the access log, but the error log has not had an entry in many hours and I've had plenty of failed download attempts since the last error entry. For example, I see these entries in my access log...
I've attached a screen shot of the error I receive in Internet Explorer when I choose "Open" or "Save" after clicking the Continue... link.
Posts: 4342
have you tried a different browser?
Posts: 19
No, I've only tried IE so far but I have tried it from multiple computers and set the security to low. But I assume you aren't suggesting IE is the problem, but rather the possibility of a setting in IE? I think trying from multiple computers more than likely rules that out.
Posts: 19
OK, so I just tried with Firefox and it works!! Any ideas why that is? I'm glad it's at least working with another browser but since IE is the most widely used browser I need to ideally get it working with it (and ideally without requiring customers to be checking settings they have no idea how to check assuming it's a settings issue).
Posts: 4342
Try with different versions of IE.
Posts: 19
All computers I tried were running IE6 SP3. I just tried a computer running IE6 SP2 and same problem. I will try IE7 with all the latest updates shortly (after one of my computers finishes updating). However, I hope this is part of a troubleshooting process. Any version of IE6 or IE7 would probably be the most commonly used browsers by customers and I can't be telling them they need to have a specific version in order to download their product.
Thanks
Posts: 19
I just tried with IE7 with all the most recent updates and it works. Now that we've determined that Firefox 3 and IE7 work, is this really the expectation? That IE6 just doesn't work? I've done tons of searches on this forum and can't find anybody else having this issue with checkout download.
Posts: 19
Is the expectation that IE6 doesn't work with Checkout Download? And if so, am I really the first person to bring this up? Anybody have any ideas at all? It seems like it's something simple that could be changed to fix this problem.
Posts: 4342
No, there's no such expectation. I have verified and can confirm that checkoutdownload does work correctly with IE6.
You'll need to do some detailed debugging with something like Fiddler, probably, to determine the cause of the problem on your website.
Posts: 19
OK, I'll see what I can find. But do you have any thoughts at all as to where you'd look first? Something on the web server side (web hosting side) or a permissions issue or a file that is out of date or something like that? At this point I'm not necessarily looking for the answer, but rather I'm just looking for anything that might pop into your head to check if you were having this problem. It just seems this is a very specific problem. It works with Firefox and it works with IE7 but it doesn't work with three different computers running IE6 (1 SP2 and 2 SP3). That is quite specific, actually.
Thanks again.
Posts: 4342
I'll pm you a link with a download from my website (which works ok in my install of IE6) and if you do likewise with one that doesn't work we can compare notes.
Posts: 4342
Actually - it only works for me in IE6 if you save the file then open it from explorer. If you click "open" from the file download dialogue box it doesn't work.
Posts: 19
The link you sent to me via PM works!! So that's really odd! If I didn't already know that IE7 and Firefox were working I would be checking permissions on my website right now. The fact that it is working via your link using "my" IE6 (so we know it's not an issue with my workstations) means that there is something different on my website that is only affecting IE6. Does this trigger any ideas? If not, then I guess I'm off to see what I can dig up.
Thanks
Posts: 4342
It's important to put all the steps to the solution in the thread - assuming the thread reaches one. It's not "clutter" at all. If you hadn't posted this (which you had sent to me by pm) then if this thread finishes here, which it's quite likely to, nobody else would know whether this was a server-side or client side problem. As it is, it's likely to be a server side issue at your end.
Posts: 19
I understand what you are saying and I agree. I'm just saying I wouldn't have abandoned this thread one way or another but I realize you have no way of knowing that. If I don't find a solution (and stop working towards one) I will post that. So anyway, I found something that looks similar...
http://bytes.com/groups/php/554529-internet-explorer-6-refusing-let-me-download
I've searched several files but can't find any reference to session_start() or anything similar. I do see where I could change the Content-Type but I'm not sure I'd want to do that. Am I barking up the wrong tree here? If not, do you have an idea where I need to look? I do assume this shouldn't be a code issue, however. It's just that this particular problem sounded so similar.
Posts: 4342
Gallery doesn't use php's session handling and never calls session_start(), so I think that's a red herring.
Posts: 19
I've run Fiddler with both IE6 and Firefox. The results (saved to a txt file) look almost exactly the same even though IE6 errors out when trying to save to disk and Firefox saves the ZIP just fine. I can see the ZIP file within the session text for both IE6 and Firefox! So, the ZIP is getting to the computer, yet IE6 errors when trying to save it. It's almost like it's downloading it and then discarding it before you can ever get a chance to save it. But as we know, this didn't happen when I tested via another Gallery website on this same computer with IE6. What gives? IE6 either is discarding the file before I can save it OR it doesn't like the format of the file (not likely) and this only happens from my website, not another website.
Posts: 4342
the zip file from my website was using the nested folders setting. Is that set on yours?
Posts: 19
I've tried it both ways with the same results. And unfortunately my web hosting provider isn't giving me a lot of help since they feel there's no way it's a server problem, that it has to be a local problem and they tested it themselves but only with IE7 (which I already told them works). Apparently they don't have access to IE6 which I find hard to believe. They could if they wanted to. Of course, I know that the same IE6 can indeed work because it worked on your site. That doesn't prove it's a server problem, it could be a problem with the Gallery installation that somehow just affects IE6. I love really specific problems like this. It seems like the solution should be obvious but so far it's not.
Posts: 4342
What happens if you save the file with IE7 then drag'n'drop it onto an IE6 window? does it unzip?
Posts: 19
Yes, which of course pretty much rules out the possibility that IE6 doesn't like the format.
Posts: 19
I'm fresh out of ideas on this. I will be sure to update this thread if I find a solution. And I'll be checking from time to time to see if anybody has any ideas.
Posts: 19
OK, I couldn't stay away for long. alecmyers, could you tell me what the Cache-Control and Pragma settings are for PHP on your website when you run the PHP Info in the Gallery Support? This is what it says for me...
Cache-Control no-store,no-cache,must-revalidate,post-check=0,pre-check=0
Pragma no-cache
I have no idea if this has anything to do with my problem but when you google all the relevant key words for this issue I get a lot of discussion forum hits that talk about these settings.
Posts: 4342
It has this:
Posts: 19
I managed to find a way to get IE6 to download the ZIP files. By changing the following in the FetchDownload.inc file...
$phpVm->header('Content-Type: application/octet-stream');
(changed to)
$phpVm->header('Content-Type: application/zip');
While this is now working in IE6, I can't help but think there's a good reason for it being set to octet-stream and not zip. Maybe you can clue me in on that. I haven't tested with any other browsers yet to see if they still work.
Does this give you any ideas as to what the problem might be? I had already determined that the ZIP was getting to my computer with IE6 by using Fiddler but for some reason IE6 was not handling it properly (even though a ZIP downloaded successfully with Firefox could be opened in IE6 no problem).
UPDATE: Although IE6 is downloading the file, it's apparently corrupted and won't open. So, obviously this is not a solution, but it proves IE6 on my computer(s) can download files via my website using Checkout Download. I'm not sure how much this helps, but...
Posts: 4342
No, sorry - I've no idea. I didn't write any of that bit of code.
Posts: 2
I too am having this problem, is there any solution or new ideas? I would really like to use this for my customers to download their finished pictures, but this is just not working. What do others to do have people download pictures from Gallery2?
Posts: 19
I have never found a solution to this problem and (for now) I have given up on this project. I may revist at some point. Hopefully somebody else will see this that has any ideas. If I ever do find a solution to this problem I will definitely post it here.
Posts: 4342
@cbuxton: I'm afraid it works perfectly for me, which makes it impossible for me to help. If you spend some tech. time debugging the problem in detail (don't assume it's the same issue as anyone else has, even if the symptoms are initially the same) and can let me know what you find out that would be helpful.