Add class to tableh1 in template.html Add class to tableh1 in template.html
 

News:

CPG Release 1.6.27
change DB IP storage fields to accommodate IPv6 addresses
remove use of E_STRICT (PHP 8.4 deprecated)
update README to reflect new website
align code with new .com CPG website
correct deprecation in captcha

Main Menu

Add class to tableh1 in template.html

Started by findingcolors, February 25, 2023, 10:06:35 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

findingcolors

In my theme I have styled tableh1, but I don't want the album information (4 albums on 1 pages(s) ) to take the tableh1 styling. How can I add a class within that specific tableh1 in the template.html?

What I want:
<tr>
<td class="tableh1" style="white-space: nowrap" width="100%" valign="middle" align="left"><span class="info">[/b]4 albums on 1 page(s)</span>[/b]</td>
</tr>

Joe Carver

That change would be done in the file themes/YourTheme/theme.php.

Review some of the docs before starting - https://coppermine-gallery.net/docs/curr/en/theme.htm

In the file themes/sample/theme.php find this section to copy whole into your theme.php
/******************************************************************************
** Section <<<$template_tab_display>>> - START
******************************************************************************/

/******************************************************************************
** Section <<<$template_tab_display>>> - END
******************************************************************************/


Make the changes as you wish to the line:
    'left_text'         => '<td width="100%%" align="left" valign="middle" class="tableh1" style="white-space: nowrap">{LEFT_TEXT}</td>' . $LINEBREAK,

Note that the changes can affect other places where left text is used