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 use thumbnails as previous/next buttons  (Read 4687 times)

0 Members and 1 Guest are viewing this topic.

Sarre

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
How to use thumbnails as previous/next buttons
« on: January 06, 2006, 09:18:42 pm »

Hi,

When looking at a photo, I would like to have a thumbnail of the previous photo as a link to that previous photo, and a thumbnail of the next photo as a link to that next photo.
How should I do this?

Thanks,
Sarre
Logged

ecto

  • Supporter
  • Coppermine frequent poster
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 144
    • My very incomplete gallery
Re: How to use thumbnails as previous/next buttons
« Reply #1 on: January 06, 2006, 10:31:12 pm »

An easy "solution" would be to enable the film strip (in Config -> Image view) and set "Number of items in film strip" to 3. You would then have "kind of" a navigation below the picture.. not complete or a "real" solution, but it might suffice?
Logged

Sarre

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Re: How to use thumbnails as previous/next buttons
« Reply #2 on: January 06, 2006, 10:36:56 pm »

I've been thinking of that allready, but I'm affraid it wouldn't help, as I need to be able to position the images at the top of the page...

What I need to know, is how to pass the url of the previous image and the url of the next image into the $template_img_navbar block.
Perhaps changing the filmstrip code somewhat might work, but I have no idea how to do that...

Thanks for the answer though!
Logged

ecto

  • Supporter
  • Coppermine frequent poster
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 144
    • My very incomplete gallery
Re: How to use thumbnails as previous/next buttons
« Reply #3 on: January 06, 2006, 11:05:47 pm »

As some kind of start for further coding, $params in function theme_html_img_nav_menu() should include new keys, like NEXT_THUMB_URL and PREV_THUMB_URL. Then just edit $template_img_navbar to include that instead of the standard {LOCATION}images/next.gif.

Question is, as you say, how to get the URL's of prev and next thumbnails to populate $params. I haven't looked into that, dunno if I have the time..
Logged

Sarre

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Re: How to use thumbnails as previous/next buttons
« Reply #4 on: January 07, 2006, 08:38:14 pm »

Hi
I took a new look into the filmstrip function, and managed to change it so that it only shows the previous and next thumbnail!
Thanks for the advice!
Logged
Pages: [1]   Go Up
 

Page created in 0.026 seconds with 19 queries.