Using own Thumbnails Using own Thumbnails
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Using own Thumbnails

Started by esugrue, March 10, 2005, 04:12:32 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

esugrue

Hi!

I am trying to upload my own thumbnails for CPG (1.3.2) to use. I want all thumbs to be the same size (eg: 75x75)

Unfortunately I have already uploaded my images and CPG has created thumbs itself so is it possible to replace CPGs thumbs with mine.

I tried uploading my own thumbs and replacing the thumb_ files but it's still resizing them to the original thumb size it created (getting it from Sql database maybe?). Anyway around this apart from uploading all my thumbs and recreating all new galleries?

Thanks
Ernie

Joachim Müller

upload your custom thumbs, then go to "admin tools" and chose "Update thumbs and/or resized photos" with the option "Only thumbnails" selected. Not completely sure if this does what you're up to, but worth a try. Another solution is to edit the database entries (thumbnail dimensions) directly in phpMyAdmin (or similar). Another option is to remove the width and height attributs of the <img> tag for thumbnails (with a small penalty on performance and standards compliance).

Joachim

esugrue

Hi:

Thanks for the help, I've tried but am still having problems.

If I upload my 75x75 thumbs and then go to Admin Tool and update thumbs it recreates the thumbs again (hence overwriting my thumbs).

I am unsure where to look to find the height/width attributes for the thumbs on the generated page. I looked in theme.php which seems to be the page that creates the output page but cannot find where it's mentioned. I was thinking maybe to try and change the page generation to height=75 width=75 rather than remove the dimensions altogether.

Since I have 14000 images already added, this maybe my best/only reasonable option.

So where can I go to change to force code the thumb size on the generated page(s)

Thanks heaps
Ernie

omniscientdeveloper

Upload your thumbs then set the size to 75 in config. That should be all you have to do.

esugrue

Hi!

I tried that but still no luck. Here's what I'm doing/done!

I've already added 14000 images into 200+ albums and when I added them CPG created thumbnails to 75px (max aspect) as in the config.

I want to upload my own thumbnails that are 75x75 cropped.

I have tried:

1) Simply uploading the thumbs - but the original thumb dimensions must be in the sql table as it resizes my 75x75 to what it originally created the thumbnail as (eg: 75x60, 55x75 etc).

2) I tried uploading my thumbnails (75x75) and going to Admin Tools and updating the thumbnails only, but it went through and said they were all done correctly, but it recreated all the thumbnails. So it was back to the beginning.

I can set the size in config to 75 but I only get a Height, Width or Max Aspect choice (none of which is suitable as I want all thumbs to be 75x75 cropped to aspect).

I was going to edit the thumbnail page where they were displayed but cannot find the code to edit (if I can do this at all!).

Thanks
Ernie

Venus

I m not sure what exactly is your problem but I have similar I've uploaded my own thumbs 75x80 and they are resized by cpg to 75x91 they look good but around them is black "border" and it is not looking good. Does anyone know if there is possibility to remove it?

(https://coppermine-gallery.com/forum/proxy.php?request=http%3A%2F%2Fimg29.exs.cx%2Fimg29%2F1104%2Fthumby7fo.jpg&hash=65e1872e88c6ad1e476872656951af2f270ae9b2)

Nibbler

Change to a different theme and see if the border goes away.

Venus

I fixed it :)

Esugrue if you go to config at put there 75 as max height it will resized your width a little but it will still looking good. I done it this way on my site and it works. I think there is no way to put them to be 75x75.