News:

cpg1.5.44 Security release - upgrade mandatory!The Coppermine development team is releasing a security update for Coppermine in order to counter recently discovered vulnerabilities. It is important that all users who run version cpg1.5.42 or older update to this latest version as soon as possible.[more]

I have several categories with albums that are keyword based only. I was wondering if it is possible to set a category thumbnail when the albums in the category are keyword based. I can set thumbnails on the category where the pictures were actually uploaded to without issue.

I don't see anything in the database that would prevent this.The category (in cpg_categories) would need the 'thumb' value set to the 'pid' of the desired picture...

The interface determines the list of eligible pictures in catmgr.php on line 208 at 1.5.26 looking for pictures in albums contained in the category.The logic here would need to be altered to also include pictures with a keyword(picture can have more than one - space separated by default, but could be another character based on config value) that matches the album keyword...

I was a little surprised when I went to the category and the set picture was not there. I was able to set all the thumbnail for the keyword based albums. I thought for sure the category would be able to do the same. No problem setting thumbnail on category that contained albums where the pictures were uploaded.

The case of non-user categories is simple... And I think has been tested... Just creating a new category and having albums in it with no directly added pics - just keywords... I'll apply your code and verify this again.

For user galleries, even if photos are directly added, where do I specify the category photo? It seems to show last uploaded for each when viewing index.php?cat=1 - and I see no place to set a 'category photo'.

If I define a new user and add a single album specifying a keyword used in public albums... It displays the public photos with that keyword when logged on as that user and selecting 'My Gallery' (index.php?cat=10006) - but does not show in 'User Gallery' view (index.php?cat=1)User keyword only albums don't seem to appear in the count of Albums in User Galleries on index.php...

If you open the category manager and edit a category, you can set a category thumbnail. Before the change, Coppermine just regards pictures of albums that reside in the current category. After the change, Coppermine also regards linked pictures. This means the linked pictures will be listed additionally. If there are no "regular" pictures, you wasn't able to set a category thumb, as the option wasn't displayed.

Tested on 1.5.26 and SVN 8660.Linked pictures are now selectable for category thumbnails - including the overall 'user gallery' category.Categories containing only albums with no direct photos now display the option to select a thumbnail from the list of linked photos.