forum.coppermine-gallery.net

Dev Board => cpg1.4 Testing/Bugs => cpg1.4 Testing/Bugs: FIXED/CLOSED => Topic started by: donnoman on March 29, 2005, 01:07:31 am

Title: Custom thumbs issue
Post by: donnoman 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.

Title: Re: Custom thumbs issue
Post by: omniscientdeveloper on March 29, 2005, 02:00:31 am

Have you made sure the extension for the thumbs are lowercase?
Title: Re: Custom thumbs issue
Post by: donnoman 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.
Title: Re: Custom thumbs issue
Post by: Casper 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.
Title: Re: Custom thumbs issue
Post by: Joachim Müller on April 09, 2005, 01:35:50 pm
*bump*
Title: Re: Custom thumbs issue
Post by: donnoman 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.
Title: Re: Custom thumbs issue
Post by: donnoman 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

Title: Re: Custom thumbs issue
Post by: donnoman 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?
Title: Re: Custom thumbs issue
Post by: Joachim Müller on April 10, 2005, 10:53:39 am
yes, please commit. Anything that fixes the issue is fine.

Joachim
Title: Re: Custom thumbs issue
Post by: Casper 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
Title: Re: Custom thumbs issue
Post by: donnoman 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.