Multiple file upload using a ZIP archive (updated for 1.4.3) Multiple file upload using a ZIP archive (updated for 1.4.3)
 

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

Multiple file upload using a ZIP archive (updated for 1.4.3)

Started by tonyhill, February 13, 2006, 05:43:39 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

tonyhill

This work is based upon RatKing's mod, first referenced here:
http://forum.coppermine-gallery.net/index.php?topic=7750.0

I've incorporated Guerilla's fix into upload.php and ported this mod to 1.4.3.  This fix was found here:
http://forum.coppermine-gallery.net/index.php?topic=21947

groupmgr.php has changed very significantly in the areas of interest between 1.3.4 and 1.4.3, so I left groupmgr.php as is in 1.4.3.  Replacing the remaining two files, upload.php and english.php allowed the mod to work.

The modified files, along with m-zip.php are included in the attached zip file.

I had to make a few guesses to adapt the mod.  Maybe someone can help out to make sure this thing is 100% correct.

The first guess is in english.php
array('All files found in a unpacked ZIP get the same title and comment','single_zip_info_entry',1,''),

I added the last element of the array to match the surrounding arrays.  I have no idea what the purpose of that last element is, so I left it blank.

The second guess has to do with my exclusion of groupmgr.php from any modifications.  I have no idea what the purpose of this file is, or what the modifications do to groupmgr.php.  This file has changed extensively from 1.3.4, so I just didn't touch it.  Was this wise?

Many thanks to RatKing and all for putting this together in the first place!  It saves me a lot of headache.

LilAngel

It sounds like something I could use. Have you experienced any bugs or problems? Is there anyone else who has tried this?

Edit:
Do I have to only upload the files in your ZIP file or should I also use Ratkings/Guerillas work?

Edit 2:
I uploaded the files from your ZIP archive, but it seems I only can upload zip archives now.. File uload boxes and URI upload boxes have gone.
Uploading files via that ZIP works. :)
However, I am getting some notices in debug mode. I am not sure if these are important but it might have to do with the problem I am having. Php is like French for me, I can read it, but understanding is something different  :-[

/upload.php

    * Notice line 1056: Undefined index: file_upload_array
    * Notice line 1309: Undefined index: URI_array
    * Notice line 2126: Undefined variable: path_to_image
    * Notice line 2275: Undefined variable: file_failure_array
    * Notice line 2276: Undefined variable: URI_failure_array
    * Notice line 2277: Undefined variable: zip_failure_array

/m-zip.php

    * Notice line 117: Undefined index: ./albums/edit/mZIP_temp_b6c69ac6.zip
    * Notice line 120: Undefined index: ./albums/edit/mZIP_temp_b6c69ac6.zip
    * Notice line 211: Undefined variable: m_zip_fileHandle
    * Notice line 211: Undefined variable: m_zip_fileHandle

Joachim Müller

turn off notices_display if they don't mean anything to you, they're a dev-only feature.

ftree

Hi

I have installed the files and it works great.
But I have the same problem as LilAngel that I only see the Zip Upload Input Filed.
Waht do I have to do that I can see the File uload boxes and URI upload boxes also.

lg flo

Joachim Müller

mods only go supported on the mod thread. The mod you're refering to has been made for cpg1.3.x, it can't be used out-of-the-box with cpg1.4.x. Basically, you're on your own with this - either find out how to make the mod work with cpg1.4.x by yourself or don't use that mod.