Advanced search  

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]

Pages: [1]   Go Down

Author Topic: Support for Tiff Image Display Modification  (Read 5407 times)

0 Members and 1 Guest are viewing this topic.

Garibaldi

  • Contributor
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 100
    • Wisconsin Collector Car
Support for Tiff Image Display Modification
« on: July 29, 2009, 10:09:04 pm »

This thread is for support of the Tiff Image Display Modification. Please post your questions here and I'll do my best to answer them.
Logged

Kodak_SLRc

  • Coppermine newbie
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 10
Re: Support for Tiff Image Display Modification
« Reply #1 on: October 29, 2009, 11:29:08 pm »

Hello Garibaldi,

Thank you very much for this invaluable code! I have tried to be very careful and follow the mod exactly. However I cannot get a .tif to upload. I had a little trouble getting ImageMagick to work until I found that the trailing "/" was required on the path (/usr/bin/). Then it works fine with .jpg and .png uploads.

With .tif I get:

"Notices
/upload.php
Notice line 2142: Undefined variable: escrow_array
Notice line 2143: Undefined variable: file_failure_array
Notice line 2144: Undefined variable: URI_failure_array
Notice line 2145: Undefined variable: zip_failure_array"

Any ideas?

Thank you in advance,
Tom
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Support for Tiff Image Display Modification
« Reply #2 on: October 31, 2009, 11:47:17 am »

Turn notices_display off in Coppermine's config if you don't know what they are meant to be used for. Instead, do as suggested per board rules (you agreed to respect them when signing up) and post a link to your gallery for a start.
Logged

Kodak_SLRc

  • Coppermine newbie
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 10
Re: Support for Tiff Image Display Modification
« Reply #3 on: October 31, 2009, 05:13:02 pm »

Logged

Garibaldi

  • Contributor
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 100
    • Wisconsin Collector Car
Re: Support for Tiff Image Display Modification
« Reply #4 on: November 03, 2009, 05:31:20 am »

Hi Tom,

Sorry this reply took so long. I tried uploading a tiff to your site and I see the error now is "Forbidden file extension.". Try these steps to resolve this issue:
1. Download and install the "Filetype Editor" plugin from http://coppermine-gallery.net/plugins.php
2. In this plugin, add tiff and tif image filetypes. I've attached a screenshot of what the configuration should look like
3. Try uploading a tiff again and let me know what happens
Logged

Kodak_SLRc

  • Coppermine newbie
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 10
Re: Support for Tiff Image Display Modification
« Reply #5 on: November 04, 2009, 09:21:14 pm »

Hello Garibaldi,
Thank you very much for looking at this.
- I installed the filetypes editor. The types were there but set as document; I changed them to image.
- Tried a .tif upload and got "0 uploads were successful."
- I confirmed that "Max size for uploaded files (KB)" was big enough (30,720).
- I confirmed that "Max width or height for uploaded pictures/videos (pixels)" was big enough (5120).

Struggling for ideas, I decided to make a little .tif, just 150 KB or so. Voila, it uploaded. The tiff_download directory was created and the .tif file was in it with a gobbledygook file name, f7c3a521.tif. I made another version of it with LZW compression and that worked too. (Although, I don't see how a user can get to the .tif to download it through the CPG interface.)

Tried all this again with incrementally larger file sizes. Only used LZWs. The cutoff is is somewhere between 1.4 MB and 2.5 MB.

So now, two issues remain:
1) How to set the file size limit up to around 30 MB, and
2) How does the user access the actual .tif file for download?

Thank you very much in advance,
Tom

http://www.thomasrobertfrederick.com/pal/images_test/
Username: guest
Password: guest
Logged

Garibaldi

  • Contributor
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 100
    • Wisconsin Collector Car
Re: Support for Tiff Image Display Modification
« Reply #6 on: November 04, 2009, 09:26:54 pm »

Hi Tom,

Ah, I believe I know what your problem is. You need to edit your PHP settings to allow for larger filesize uploads (it's probably at 2MB atm). Locate your php.ini file and search for the upload section. I believe the line you're looking for is "max_upload_size" or something like that
Logged

Kodak_SLRc

  • Coppermine newbie
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 10
Re: Support for Tiff Image Display Modification
« Reply #7 on: November 06, 2009, 12:21:53 am »

Hello Garibaldi,

Yes, that did it. I set upload_max_filesize = 32M, it was 2. Also while I was nosing around in there I set memory_limit = 128M, guessing this would give ImageMagick more room to work. Also got a warning about register_globals being on, so I turned it off.

Still had some troubles, though. Had problems uploading more than one at a time, so I just uploaded one at a time. Everything seemed good. I decided to clean up by deleting the album created by guest.

Then I noticed (though it may have been there before I deleted guest's album)... Somehow, when one clicks on the TIFFs album, all 18 images are listed. (There should be 9 images in JPEGs and 9 images in TIFFs). Doggoneit! Ran "update database" in Admin Tools but that didn't help or indicate any problems. Then, just fiddling around, clicked on Home, then Edit Files (of the TIFF album), edited some keywords and applied modifications, and POOF! The TIFF album shows just the 9 images that it should, with the handy link to the actual .tif file! The JPEG album works correctly also.

So at the moment, all is working perfectly! Hope this posting helps others. Thank you very much for your assistance and for this invaluable mod. Very much appreciated!

Best,
Tom
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Support for Tiff Image Display Modification
« Reply #8 on: November 06, 2009, 07:52:05 am »

I set memory_limit = 128M, guessing this would give ImageMagick more room to work.
Afaik ImageMagick is not affected by the limitations imposed on PHP by php.ini. The limitations only apply when using GD, because that is compiled in into PHP, while ImageMagick is an external executable that PHP sends data to to process.
Logged
Pages: [1]   Go Up
 

Page created in 0.021 seconds with 19 queries.