Download Images

rasheid

Joined: 2004-08-31
Posts: 28
Posted: Wed, 2004-09-01 18:15

I was wondering if G2 has the ability to download images in my lightbox to my machine instead of printing them somewhere?

Any help with this would be greatly appreciated.

-rasheid

 
bharat
bharat's picture

Joined: 2002-05-21
Posts: 7994
Posted: Thu, 2004-09-02 05:54

At the moment, G2 doesn't have a lightbox. Or perhaps you're referring to the cart? We can write a cart plugin to download everything in the cart as a zip. That's a good idea!

 
rasheid

Joined: 2004-08-31
Posts: 28
Posted: Thu, 2004-09-02 21:22

That would be awsome.

Please let me know on that. I would like to be able to do that for my internal storage

 
rubdub

Joined: 2004-08-28
Posts: 12
Posted: Fri, 2004-09-03 14:50

Yes please Bharat. I could use this zip download too.

Rob

 
mindless
mindless's picture

Joined: 2004-01-04
Posts: 8601
Posted: Fri, 2004-09-03 19:45

Here's a very rough start.. it has a hardcoded path to "zip", it doesn't check permissions yet and sometimes will have the wrong filenames in the zip file (if you have a preferred derivative) but it does the basics. Sometime later I'll clean it up, add unit tests, and get it into CVS.

Unzip the attached file in your "modules" directory, then edit zipcart/classes/ZipCartPlugin.class and set the correct path to "zip" on your system. Then install/activate the module.. enjoy!

 
rasheid

Joined: 2004-08-31
Posts: 28
Posted: Tue, 2004-09-07 16:40

I get this error when I try and download the zipped files.

Any ideas?

Error (ERROR_PLATFORM_FAILURE)
• in modules/zipcart/classes/ZipCartPlugin.class at line 98 (gallerystatus::error)
• in modules/cart/ModifyCart.inc at line 126 (zipcartplugin::fulfillcart)
• in main.php at line 150 (modifycartcontroller::handlerequest)
• in main.php at line 29

 
mindless
mindless's picture

Joined: 2004-01-04
Posts: 8601
Posted: Tue, 2004-09-07 16:43

Probably you didn't put the correct path to zip in ZipCartPlugin.class.
Otherwise turn on buffered debug output to see what the zip command is doing.

 
rasheid

Joined: 2004-08-31
Posts: 28
Posted: Tue, 2004-09-07 16:48

should I be setting up a new directory, or pointing at an existing one?

-rasheid

 
mindless
mindless's picture

Joined: 2004-01-04
Posts: 8601
Posted: Tue, 2004-09-07 17:28

What directory? zip is an executable file.
Did you find '/usr/local/bin/zip' in ZipCartPlugin.class? Change this to the full path to zip on your server.

 
rasheid

Joined: 2004-08-31
Posts: 28
Posted: Tue, 2004-09-07 18:11

ahh thanks

 
rasheid

Joined: 2004-08-31
Posts: 28
Posted: Tue, 2004-09-07 18:53

Sorry for my ignorance, but I am kinda lost here.

How would I be able tell that I going to right place?

I haven't been able to locate the actual file, or path to it.

Would the file already exist on my server?

 
fryfrog

Joined: 2002-10-30
Posts: 3236
Posted: Tue, 2004-09-07 19:07

try... the "which" command which may result in something like the following below.

nightcrawler showeq # which zip
/usr/bin/zip
 
rasheid

Joined: 2004-08-31
Posts: 28
Posted: Tue, 2004-09-07 19:21

gotit.

sorry, I was confusing myself

-rasheid

 
mindless
mindless's picture

Joined: 2004-01-04
Posts: 8601
Posted: Sun, 2004-09-26 07:03

Zip Download module now added to cvs.

 
Roshlin

Joined: 2004-09-14
Posts: 70
Posted: Sun, 2004-09-26 10:01

Hi friends,

Nice mod. very practical.

Could we take this a step further.
Add a button on the cart "send for printing" which would send the zip file to the administrator with details of the quantities by email.

Thanks

 
futurepublic

Joined: 2006-01-21
Posts: 2
Posted: Wed, 2006-01-25 22:34

This zip module is great. Apologies if this is picked up in another thread, but it would be amazing if the administrator could be notified when members actually download files.

If any experts out there could explain how to tell who has downloaded what pictures, I'd be hugely grateful.

Thanks

 
mindless
mindless's picture

Joined: 2004-01-04
Posts: 8601
Posted: Thu, 2006-01-26 00:30

The module currently does not record anything for downloads that occur.