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: Custom thumbs issue  (Read 8529 times)

0 Members and 1 Guest are viewing this topic.

donnoman

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1615
  • From donovanbray.com
    • Donovan Bray
Custom thumbs issue
« on: March 29, 2005, 01:07:31 am »

I wonder if someone else can confirm what I'm experiencing.

When adding custom thumbnails to an album the thumbnails become 1px x 1px tall. In Editpics they show correctly.

« Last Edit: April 10, 2005, 05:16:19 pm by donnoman »
Logged

omniscientdeveloper

  • VIP
  • Coppermine addict
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 901
Re: Custom thumbs issue
« Reply #1 on: March 29, 2005, 02:00:31 am »


Have you made sure the extension for the thumbs are lowercase?
Logged

donnoman

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1615
  • From donovanbray.com
    • Donovan Bray
Re: Custom thumbs issue
« Reply #2 on: March 29, 2005, 03:20:44 am »

Only one was uppercase as it was; changed it to lowercase, no change in the thumbs issue. But good thought.
Logged

Casper

  • VIP
  • Coppermine addict
  • ***
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 5231
Re: Custom thumbs issue
« Reply #3 on: March 29, 2005, 09:01:09 pm »

Did you check the extensions for the main files as well, that also causes problems.  Also if there are spaces in any of the folder names.
Logged
It has been a long time now since I did my little bit here, and have done no coding or any other such stuff since. I'm back to being a noob here

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Custom thumbs issue
« Reply #4 on: April 09, 2005, 01:35:50 pm »

*bump*
Logged

donnoman

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1615
  • From donovanbray.com
    • Donovan Bray
Re: Custom thumbs issue
« Reply #5 on: April 10, 2005, 01:16:53 am »

both original filenames and the thumbs are all using lowercase names and extensions and I still see the same behaviour.
Logged

donnoman

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1615
  • From donovanbray.com
    • Donovan Bray
Re: Custom thumbs issue
« Reply #6 on: April 10, 2005, 02:57:54 am »

I moved the files from my production gallery to my test gallery and reproduced the problem.

I didn't notice on my production gallery because I had notices turned off, my development gallery however outputs the following:

Code: [Select]

\include\functions.inc.php
Warning line 1685: getimagesize(albums/Distribution%20Frame%20Solutions/thumb_adc-edf.jpg): failed to open stream: No such file or directory
Warning line 1685: getimagesize(albums/Distribution%20Frame%20Solutions/thumb_adc-structured.jpg): failed to open stream: No such file or directory
Warning line 1685: getimagesize(albums/Distribution%20Frame%20Solutions/thumb_apc-infrastruxure.jpg): failed to open stream: No such file or directory
Warning line 1685: getimagesize(albums/Distribution%20Frame%20Solutions/thumb_apc-networkair-cm.jpg): failed to open stream: No such file or directory
Warning line 1685: getimagesize(albums/Distribution%20Frame%20Solutions/thumb_apc-networkair-pa.jpg): failed to open stream: No such file or directory

Logged

donnoman

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1615
  • From donovanbray.com
    • Donovan Bray
Re: Custom thumbs issue
« Reply #7 on: April 10, 2005, 03:15:32 am »

in display_thumbnails I added a urldecode() to the getimagesize call and it fixed the problem.

Code: [Select]
                        if (!is_image($row['filename'])) {
                                $image_info = getimagesize(urldecode($pic_url));
                                $row['pwidth'] = $image_info[0];
                                $row['pheight'] = $image_info[1];
                        }

Shall I commit?
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Custom thumbs issue
« Reply #8 on: April 10, 2005, 10:53:39 am »

yes, please commit. Anything that fixes the issue is fine.

Joachim
Logged

Casper

  • VIP
  • Coppermine addict
  • ***
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 5231
Re: Custom thumbs issue
« Reply #9 on: April 10, 2005, 12:23:59 pm »

I moved the files from my production gallery to my test gallery and reproduced the problem.

I didn't notice on my production gallery because I had notices turned off, my development gallery however outputs the following:

Code: [Select]

\include\functions.inc.php
Warning line 1685: getimagesize(albums/Distribution%20Frame%20Solutions/thumb_adc-edf.jpg): failed to open stream: No such file or directory

That explains why it was happening though, you have spaces in your folder names.

Also if there are spaces in any of the folder names.

Good to see this fixed
Logged
It has been a long time now since I did my little bit here, and have done no coding or any other such stuff since. I'm back to being a noob here

donnoman

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1615
  • From donovanbray.com
    • Donovan Bray
Re: Custom thumbs issue
« Reply #10 on: April 10, 2005, 05:16:03 pm »

The whole gallery was created with Nibbler's Timer.php. And the directory names become the cat's and alb's so using spaces is a necessity If I wanted the end result to look good.

I comitted my fixes, there were more instances of that line in three different files that I committed as well.

Marking fixed.
Logged
Pages: [1]   Go Up
 

Page created in 0.023 seconds with 19 queries.