Remove Album/File numbers for category levels Remove Album/File numbers for category levels
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Remove Album/File numbers for category levels

Started by BabeandJamie4Ever, November 25, 2014, 10:13:51 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

BabeandJamie4Ever

Hi,

I've done some searching but all I can find are threads of people wanting to be able to do this, not any showing how to get rid of it. How do we stop the main page of the gallery from displaying the number of files/albums next to each category as well as other categories that don't have albums in them? We don't want it showing which sections we are more up to date on than others like that. Thank-you :)

http://star-kidz.net/imagearchive/

nowordneeded

I posted about this last night. Still no answer on my thread.
Sometimes my musings are too confusing for someone not inside my head.

allvip

#2
Copy function $template_cat_list from themes/sample/theme.php (first check if you alredy have it in your theme.php ) and:

1) Delete this code to delete Albums    Files text:


                <td class="tableh1" width="10%" align="center">{ALBUMS}</td>
                <td class="tableh1" width="10%" align="center">{PICTURES}</td>


and change 80% to 100% in this line of code:


                <td class="tableh1" width="80%" align="left">{CATEGORY}</td>


2) Delete this code to delete the numbers:


                <td class="catrow" align="center">{ALB_COUNT}</td>
                <td class="catrow" align="center">{PIC_COUNT}</td>



This is function $template_cat_list with the above code deleted.

/******************************************************************************
** Section <<<$template_cat_list>>> - START
******************************************************************************/
// HTML template for the category list
$template_cat_list = <<<EOT
<!-- BEGIN header -->
        <tr>
                <td class="tableh1" width="100%" align="left">{CATEGORY}</td>
        </tr>
<!-- END header -->
<!-- BEGIN catrow_noalb -->
        <tr>
                <td class="catrow_noalb" colspan="3"><table border="0"><tr><td align="left">{CAT_THUMB}</td><td align="left"><span class="catlink">{CAT_TITLE}</span>{CAT_DESC}</td></tr></table></td>
        </tr>
<!-- END catrow_noalb -->
<!-- BEGIN catrow -->
        <tr>
                <td class="catrow" align="left"><table border="0"><tr><td>{CAT_THUMB}</td><td><span class="catlink">{CAT_TITLE}</span>{CAT_DESC}</td></tr></table></td>
        </tr>
        <tr>
            <td class="tableb tableb_alternate" colspan="3">{CAT_ALBUMS}</td>
        </tr>
<!-- END catrow -->
<!-- BEGIN footer -->
        <tr>
                <td colspan="3" class="tableh1" align="center"><span class="statlink">{STATISTICS}</span></td>
        </tr>
<!-- END footer -->
<!-- BEGIN spacer -->
        <img src="images/spacer.gif" width="1" height="7" border="" alt="" /><br />
<!-- END spacer -->

EOT;
/******************************************************************************
** Section <<<$template_cat_list>>> - END
******************************************************************************/


You can delete all the tr if you don't want Category text either:


        <tr>
                <td class="tableh1" width="80%" align="left">{CATEGORY}</td>
                <td class="tableh1" width="10%" align="center">{ALBUMS}</td>
                <td class="tableh1" width="10%" align="center">{PICTURES}</td>
        </tr>

allvip

Here is a code to edit the categories (not delete) if you need it in the future:

http://forum.coppermine-gallery.net/index.php/topic,70393.0.html

and this plugin usefull plugin for more category and albums options:

http://forum.coppermine-gallery.net/index.php/topic,64270.0.html