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: Switchable metalbum most viewed  (Read 2582 times)

0 Members and 1 Guest are viewing this topic.

altenae

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 254
Switchable metalbum most viewed
« on: November 27, 2011, 04:11:00 pm »

Hi,

I have created in the functions.inc.php the following new cases:

topnd => most viewed today
topnw => most viewed last week
topnm => most viewed last month

These new metalbums are visible on the main screen bij adding these in the config.

So right now you see al three in the main page.

What I want is to see only one (let's say topnd as default) and that you can switch to topnw or topnm.
Maybe this can be done with tabs on the mostviewed block or another solution.

I know it can be switched with commands like this:

display_thumbnails('topnd', $cat, 1, $CONFIG['thumbcols'], max(1, $matches[2]), false);
etc.

But I am unable to get this working.
Anyone with a solution ?
Logged

altenae

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 254
Re: Switchable metalbum most viewed
« Reply #1 on: November 27, 2011, 06:42:44 pm »

Here an example how I want it to be/work
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15764
Re: Switchable metalbum most viewed
« Reply #2 on: November 28, 2011, 04:06:40 pm »

I assume the most easiest solution would be to remove that meta albums from "The content of the main page", and add all functionality via the anycontent.php file with your already suggested code. Then you have to embed each meta album to a div block with a unique ID. The rest should be done with some JS / CSS code.
Logged

altenae

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 254
Re: Switchable metalbum most viewed
« Reply #3 on: November 28, 2011, 04:09:07 pm »

Oke,

For me this to much...(not enough knowledge)
Let me know if you are interested for this mod.

The functions.inc already has all the special things.

Edward
Logged

altenae

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 254
Re: Switchable metalbum most viewed
« Reply #4 on: December 02, 2011, 11:06:56 pm »

Thanks Andre...Works super....
Logged
Pages: [1]   Go Up
 

Page created in 0.018 seconds with 19 queries.