forum.coppermine-gallery.net

Support => cpg1.5.x Support => cpg1.5 themes (visuals) => Topic started by: BabeandJamie4Ever on November 25, 2014, 10:13:51 pm

Title: Remove Album/File numbers for category levels
Post by: BabeandJamie4Ever on November 25, 2014, 10:13:51 pm
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/ (http://star-kidz.net/imagearchive/)
Title: Re: Remove Album/File numbers for category levels
Post by: nowordneeded on November 26, 2014, 04:53:45 am
I posted about this last night. Still no answer on my thread.
Title: Re: Remove Album/File numbers for category levels
Post by: allvip on November 30, 2014, 02:27:26 pm
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:

Code: [Select]
                <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:

Code: [Select]
                <td class="tableh1" width="80%" align="left">{CATEGORY}</td>

2) Delete this code to delete the numbers:

Code: [Select]
                <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.
Code: [Select]
/******************************************************************************
** 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:

Code: [Select]
        <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>
Title: Re: Remove Album/File numbers for category levels
Post by: allvip on November 30, 2014, 02:50:09 pm
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 (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 (http://forum.coppermine-gallery.net/index.php/topic,64270.0.html)