[SOLVED] Zip Cart Module

crux

Joined: 2002-12-06
Posts: 61
Posted: Tue, 2005-03-08 22:12

I searched and read the faqs. I have downloaded the zip.exe file from Info-Zip and cannot get gallery to accept it. I continue to get the following message:
Unable to create a zip file from this binary

Thanks for your help.

<Please check the G2 FAQ (sticky topic in this forum) before posting!>
----

Gallery URL (optional):
Gallery version:Gallery2 Dark Fibre
Webserver (with version):Apache
Datatabase (with version):MYSQL
PHP version (eg 4.2.1):
phpinfo URL (optional):
Graphics Toolkit(s):
Operating system:W2K
Web browser/version:IE
G1 version (for migration bugs):

 
mindless
mindless's picture

Joined: 2004-01-04
Posts: 8601
Posted: Tue, 2005-03-08 23:16

open a command prompt and run zip.exe
does it seem to work correctly?
try: zip.exe test.zip somefile
but replace "somefile" with an actual filename that exists. that is basically what the module does to check if the binary is valid.. it runs that and makes sure test.zip exists afterward.

 
crux

Joined: 2002-12-06
Posts: 61
Posted: Tue, 2005-03-08 23:22

Thanks for the reply. Did what you suggested and got the following:

C:\Info-Zip>zip.exe test.zip todo.txt
zip warning: TZ environment variable not found, cannot use UTC times!!
adding: todo.txt (deflated 6%)

The zip file was created and it's valid and contains the correct file and information.

Also, if it matters, it's zip 2.3 from Nov of 99.

Thanks again!

 
mindless
mindless's picture

Joined: 2004-01-04
Posts: 8601
Posted: Tue, 2005-03-08 23:30

sorry, forgot to mention it checks if the test.zip is created and that the zip program did not return an error code. i think that TZ warning is causing zip to return an error code, so you should resolve that problem.

 
crux

Joined: 2002-12-06
Posts: 61
Posted: Tue, 2005-03-08 23:46

So, could it be that I have an AMD processor and these are all compiled for Intel?

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Wed, 2005-03-09 00:06

google for the TZ issue.
a AMD vs. intel issue is very very unlikely.

 
crux

Joined: 2002-12-06
Posts: 61
Posted: Wed, 2005-03-09 14:01

Thanks. I've been googling like crazy with no luck. Most of the posts say just to ignore the error and no one that I've found comes up with a solution. I'm giving it a break for now. If I figure something out, I'll post back.

Thanks again.

 
crux

Joined: 2002-12-06
Posts: 61
Posted: Wed, 2005-03-09 14:32

Got it. For some reason, I needed to set the TZ variable in Windows:
http://science.ksc.nasa.gov/software/winvn/userguide/3_1_4.htm

Just added a line to my autoexec.bat file and rebooted.

Thanks for helping me brainstorm.

 
LFrank

Joined: 2005-02-19
Posts: 1023
Posted: Wed, 2005-03-09 14:35

Have you tried

Quote:
On MSDOS systems that do not have TZ defined in the environment, you
should make TZFIX=0 for California, -1 for Colorado, -2 for Chicago,
-3 for New York, -8 for London, -9 for Amsterdam. In the summer,
TZFIX should be manually decremented from these values. What a mess.

It would be much cleaner to set your MSDOS environmental variable TZ
in your AUTOEXEC.BAT file, and not use the TZFIX correction. Then
MSDOS gives you good GMT timestamps, and will handle daylight savings
time adjustments for you. Here are some sample lines to insert into
AUTOEXEC.BAT, depending on your time zone:

For Los Angeles: SET TZ=PST8PDT
For Denver: SET TZ=MST7MDT
For Arizona: SET TZ=MST7
(Arizona never uses daylight savings time)
For Chicago: SET TZ=CST6CDT
For New York: SET TZ=EST5EDT
For London: SET TZ=GMT0BST
For Amsterdam: SET TZ=MET-1DST
For Moscow: SET TZ=MSK-3MSD
For Aukland: SET TZ=NZT-13

Just an idea from an old project I was involved (PGP)

Lutz

 
crux

Joined: 2002-12-06
Posts: 61
Posted: Wed, 2005-03-09 15:45

Thanks. That same solution is what I mentioned above.

 
LFrank

Joined: 2005-02-19
Posts: 1023
Posted: Wed, 2005-03-09 17:49

hehe, cool ... the timestamp showed I was typing my message at the same time as you did type yours ;)

 
pnevlud

Joined: 2006-11-02
Posts: 1
Posted: Thu, 2006-11-02 18:41

Although this thread has been dormant for a while, I thought I'd add a brief comment.

Not all PCs have the autoexec.bat file anymore. You can add it, but this solution is a bit out of date now. In order to set this environment variable on Windows XP or some other similar OS...

1. Right-click on my computer and choose Properties
2. On the Advanced tab, click the Environment Variables button.
3. Create a new System Variable called TZ and enter your value from LFrank's post above.
4. Click OK to close out all dialogs.

Your environment variable is active immediately, no need to reboot.