forum.coppermine-gallery.net

Support => cpg1.3.x Support => Older/other versions => cpg1.3 Themes/Skins/Templates => Topic started by: rlm on November 22, 2004, 02:30:58 pm

Title: Removing Random Images from Album List
Post by: rlm on November 22, 2004, 02:30:58 pm
hi,

may I ask, how can I remove Random Pics from the Album List but keep it on the Category List?

Richard
Title: Re: Removing Random Images from Album List
Post by: Joachim Müller on November 22, 2004, 04:16:06 pm
you start by reading the documentation (http://coppermine.sourceforge.net/manual.php#changing) or the faq (http://coppermine.sourceforge.net/faq.php#NoLastUploads). If you still wouldn't have been able to find an answer to your question, you would have searched the board (http://forum.coppermine-gallery.net/index.php?action=search;advanced).

Joachim
Title: Re: Removing Random Images from Album List
Post by: rlm on November 22, 2004, 05:44:44 pm
hi Gaugau,

i did all that. are you saying that this question has been answered already? or maybe, i didn't explain it clearly enough:

I have included the random images on the main page when categories are shown. when a category is selected, however, and the albums within it are listed, so too are the random images. this may be normal behaviour, but in my case it's not wanted. i only want the random images to appear on the category listing, not the album listing.
 :-\\
Title: Re: Removing Random Images from Album List
Post by: donnoman on November 25, 2004, 06:32:51 pm
You can make any of the items on the main page conditional based on the cat being 0, like anycontent.

open your index.php at around line 700 you should find the case statement for "random" make it look like this

Code: [Select]
           case 'random':
                if ($cat == 0) {
                  display_thumbnails('random', $cat, 1, $CONFIG['thumbcols'], max(1, $matches[2]), false);
                }
                flush();
                break;