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: How to display thumbnails of an album  (Read 4050 times)

0 Members and 1 Guest are viewing this topic.

Arnaud01

  • Coppermine newbie
  • Offline Offline
  • Posts: 1
How to display thumbnails of an album
« on: August 30, 2015, 07:21:08 pm »

Hello,
I would like to display thumbnails of one album of my gallery on my website.
Is it possible ?

I already use cpm fetch to display thumbnails of the last pictures added.

Thanks,
Arnaud

Logged

gmc

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: us
  • Offline Offline
  • Gender: Male
  • Posts: 781
    • GMC Design Photo Gallery
Re: How to display thumbnails of an album
« Reply #1 on: August 30, 2015, 09:50:53 pm »

And the answer is: cpmfetch...
There are many options to filter media - such as:
getLastAddedMediaFrom... any of the cpmfetch functions ending in 'From' accept a source parameter that allow you to filter.
The source can be any or all of: cat, album, owner, keyword, or text.

Examples:
"cat=5,6" - Use photos from categories 5 or 6
"cat=5,6:album=10" - Use photos from categories 5 or 6 or album 10.

So to view random media from a single category:  $objCpm->cpm_viewRandomMediaFrom("cat=1",1, 4, $options);

See the cpmfetch doc for more examples (folder docs supplied with cpmfetch) or view here: http://greggallery.gmcdesign.com/cpmfetch/docs/basic

Classes: Class cpm lists all the possibilities
The tutorial gives some examples.
Logged
Thanks!
Greg
My Coppermine Gallery
Need a web hosting account? See my gallery for an offer for CPG Forum users.
Send me money
Pages: [1]   Go Up
 

Page created in 0.019 seconds with 20 queries.