coppermine-gallery.com/forum

Support => Looking for Freelancers / Paid help => Topic started by: cccc on July 29, 2005, 11:52:05 AM

Title: Need help for hiding empty categories
Post by: cccc on July 29, 2005, 11:52:05 AM
I would like to include my albums in categories
(ex. category = cat1 including albums=2001, 2003, 2004...)  and display on the homepage only the categories.
Problem : when the albums are restricted to some users, they should not appear on the homepage for unregistered users. But categories don't have this user filter and they are always displayed. For an unregistered user, If a category contains only restricted albums, it should not be displayed. At the moment, they are but are empty (no albums and pictures inside as shown on the attached picture for cat1 to cat3).

I think a test like (if in the category, albums count=0 for the current user, then dont disyplay it) sould be added in index.php.
Could someone look at it and give me his opinion ?

Thanks.



Title: Re: Need help for hiding empty categories
Post by: Joachim Müller on July 29, 2005, 12:39:38 PM
As you posted this on the paid support board, you should post your budget as well. Review the sticky thread on this sub-board for suggestions on how to post here.
Title: Re: Need help for hiding empty categories
Post by: cccc on July 29, 2005, 02:37:44 PM
OK, sorry I haven't read the sub-board rules.

My budget is $15 (paypal).
Title: Re: Need help for hiding empty categories
Post by: cccc on August 02, 2005, 11:09:20 AM
Found !

In theme.php I deleted the code in the section

<!-- BEGIN catrow_noalb -->
<!-- END catrow_noalb -->

and seems to work.
Title: Re: Need help for hiding empty categories
Post by: Joachim Müller on August 02, 2005, 03:33:58 PM
although I doubt that this is the actual solution, I will mark this thread as "closed" if it works for you