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: Thumbnail extension  (Read 3677 times)

0 Members and 1 Guest are viewing this topic.

Patrick1

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Thumbnail extension
« on: October 09, 2011, 04:23:25 pm »

I'd like the coppermine generated thumbnails to have a jpg extension, even if the uploaded file is PNG. I've looked in the admin config, but can't find any setting related. Is it possible to configure (force) the extension? If not, what hook can I use to change the IM command?
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15764
Re: Thumbnail extension
« Reply #1 on: October 11, 2011, 01:59:08 pm »

Seems that there's no plugin hook yet. Have a look at include/picmgmt.inc.php and you'll find
Code: [Select]
$thumb = $CONFIG['fullpath'] . $filepath . $CONFIG['thumb_pfx'] . $filename;
Afaik if you now replace the file extension with ".jpg" all thumbnails will be created as jpg files. I'm currently not sure if they will be found for images (i.e. if the custom thumbnail routine also works for image files), but I'm sure you'll tell us :)
Logged
Pages: [1]   Go Up
 

Page created in 0.019 seconds with 19 queries.