To make your custom made theme from cpg1.3.x work with cpg1.4.x, you will need to make some changes. Remember to back up your original files, so you can go back to a working version in case something goes wrong with the modifications.
The files to be edited would be in the particular folder of the theme in the themes folder. For example, the files for the "classic" theme could be found in themes/classic
Find:
.admin_menu a:hover { color: #000000; text-decoration: underline; }
Add after it:
td #admin_menu_anim { background-image : url(images/button_bg_anim.gif); }
Find:
.thumb_title { font-weight : bold; font-size: 80%; padding: 2px; display : block; }
Add before it:
.thumb_filename { font-size: 80%; display: block; }
Find:
.clickable_option { border-bottom : 1px dotted blue; cursor : hand; }
Replace with:
.clickable_option { border-bottom : 1px dotted blue; cursor : default; }
Insert at the bottom of style.css
#vanity a { display:block; width:57px; height:20px; margin: 3px 20px; } #vanity img {border:0} #v_php {float:left;background-image:url(../../images/powered-php.gif);} #v_php:hover {background-image:url(../../images/h_powered-php.gif);} #v_mysql {float:left;background-image:url(../../images/powered-mysql.gif);} #v_mysql:hover {background-image:url(../../images/h_powered-mysql.gif);} #v_xhtml {float:right;background-image:url(../../images/valid-xhtml10.gif);} #v_xhtml:hover {background-image:url(../../images/h_valid-xhtml10.gif);} #v_css {float:right;background-image:url(../../images/valid-css.gif);} #v_css:hover{background-image:url(../../images/h_valid-css.gif);}
Find:
.tableh2 {
background: #D1D7DC ;
color : #000000;
padding-top: 3px;
padding-right: 10px;
padding-bottom: 3px;
padding-left: 10px;
}
Replace with:
.tableh2, .catrow_noalb {
background: #D1D7DC ;
color : #000000;
padding-top: 3px;
padding-right: 10px;
padding-bottom: 3px;
padding-left: 10px;
}
Find:
.tableb {
background: #EFEFEF ;
padding-top: 3px;
padding-right: 10px;
padding-bottom: 3px;
padding-left: 10px;
}
Replace with:
.tableb , .display_media , .catrow {
background: #EFEFEF ;
padding-top: 3px;
padding-right: 10px;
padding-bottom: 3px;
padding-left: 10px;
}
Make changes as necessary.
Find:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
Replace with:
(or insert as the first line of template.html if it is missing)<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
If your theme uses a single menu, find:
{MAIN_MENU}
Replace with:
Note: the "<br />" is for classic your theme may require a different separator.{SYS_MENU}<br />{SUB_MENU}
If your theme uses two menus, Find:
{MAIN_MENU1}
Replace with:
{SYS_MENU}
Then find:
{MAIN_MENU2}
Replace with:
{SUB_MENU}
It is recommended to do this even if you're not planning to actually use them as they can be enabled or disabled according to whether the theme is defined as XHTML 1.0 Transitional Valid.
Below are the vanity icons used in the classic theme:
Find a place anywhere between <body> and </body> where you want the vanity icons to appear. Usually this should go at the bottom of the page right before the </body> tag.
Insert the vanity graphics:
{VANITY}
It's recommended to place the custom header immediately following the <body> tag and the custom footer immediately before the "{VANITY}" token or immediately before the </body> tag.
Insert the custom header:
{CUSTOM_HEADER}
Insert the custom footer:
{CUSTOM_FOOTER}
Find:
<html dir="{LANG_DIR}">
Replace with:
<!-- <html dir="{LANG_DIR}"> --> <html>
Find:
<meta http-equiv="Content-Type" content="text/html; charset={CHARSET}" />
Replace with:
<!-- <meta http-equiv="Content-Type" content="text/html; charset={CHARSET}" /> -->
Find:
{META}
Replace with:
<!-- {META} -->
Common Errors:
Make other changes as necessary.
Find:
<!-- <html dir="{LANG_DIR}"> --> <html>
Replace with:
<html dir="{LANG_DIR}">
Find:
<!-- <meta http-equiv="Content-Type" content="text/html; charset={CHARSET}" /> -->
Replace with:
<meta http-equiv="Content-Type" content="text/html; charset={CHARSET}" />
Find:
<!-- {META} -->
Replace with
{META}
Many notable things have happened that will influence your modifications to your theme.php.
It is recommended to have access to a server that is still running the theme that you are attempting to upgrade so that you can see the differences in the 1.3.x theme and the new 1.4.x theme.
The following instructions will have you create a theme.php from scratch, only moving over and modifying the items that are different than Coppermine's internal theme "Classic".
Insert the following:
<?php /************************* Coppermine Photo Gallery ************************ Copyright (c) 2003-2010 Coppermine Dev Team v1.0 originally written by Gregory Demar This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 3 as published by the Free Software Foundation. ******************************************** Coppermine version: 1.5.4 $Source: $Revision: $LastChangedBy: $Date: **********************************************/ ?>
You now have a functional theme.
**********************************************/ ?>
The location for the ratings graphics will be directed to the themes images folder.
if your theme's images folder contain these filenames insert the define
define('THEME_HAS_RATING_GRAPHICS', 1);
The location for the navbar graphics will be directed to the themes images folder.
If you have some of these graphics it could be that the original author did not keep the same names; you will need to rename the graphics to conform to the define, or you will need to modify the navbar template directly.
if your theme's images folder contain these filenames insert the define
define('THEME_HAS_NAVBAR_GRAPHICS', 1);
Copy classic's report.gif or create a new report.gif for your theme if you set the define
The location for the film strip graphic will be directed to the themes images folder.
This define specifies a single tile to be used for both locations.
if your theme's images folder contains the above filename insert this define
define('THEME_HAS_FILM_STRIP_GRAPHIC', 1);
The location for the film strip graphics will be directed to the themes images folder.
This define specifies TWO tiles.
if your theme's images folder contains these filenames insert this define
define('THEME_HAS_FILM_STRIP_GRAPHICS', 1);
If the theme is defined as XHTML10_TRANSITIONAL the VANITY footer will be enabled. You shouldn't enable this until you've been able to follow the validation methodology discussed later in this document.
if your theme has passed the validation methodology insert this define:
define('THEME_IS_XHTML10_TRANSITIONAL',1);
When present the system won't attempt to replace the token {BUTTONS} in the SYS_MENU template. The entire block needs to be present.
Only set this after you determine you can't use the buttons template!
If you can't use the SYS_MENU buttons template insert this define:
define('THEME_HAS_NO_SYS_MENU_BUTTONS', 1);
if you have set the define your theme.php will need to set the "$template_sys_menu", this may be in your theme.old.php as part of "$template_main_menu" or all of "$template_main_menu1".
When present the system won't attempt to replace {BUTTONS} in the SUB_MENU template The entire block needs to be present.
Only set this after you determine you can't use the buttons template!
If you can't use the SUB_MENU buttons template insert this define:
define('THEME_HAS_NO_SUB_MENU_BUTTONS', 1);
if you have set the define your theme.php will need to set the "$template_sub_menu", this may be in your theme.old.php as part of "$template_main_menu" or all of "$template_main_menu2".
Classic uses a "::" separator between each menu option that you can override by modifying the "$template_sys_menu_spacer"
// HTML template for template sys_menu spacer $template_sys_menu_spacer ="::";
Insert into your theme.php and modify to suit
The sub menu templates are automatically inherited from sys menu's and you override them in exactly the same way
"$template_sys_menu_spacer" and "$template_sub_menu_spacer" are only rendered BETWEEN active elements.
Insert into your theme.php and modify to suit
// HTML template for sys_menu $template_sys_menu = <<<EOT |{BUTTONS}| EOT; // HTML template for template sys_menu spacer $template_sys_menu_spacer ="|";
Copy a button from your theme.old.php from $template_main_menu, $template_main_menu1, or $template_main_menu2 and put it in between the "<!-- BEGIN {BLOCK_ID} -->" and "<!-- END {BLOCK_ID} -->" lines and change the "{TOKENS}" as necessary.
Insert into your theme.php and modify to suit
// HTML template for sys_menu $template_sys_menu = <<<EOT <div class="topmenu"> <table border="0" cellpadding="0" cellspacing="0"> <tr> {BUTTONS} </tr> </table> </div> EOT; // HTML template for template sys_menu buttons $template_sys_menu_button = <<<EOT <!-- BEGIN {BLOCK_ID} --> <td><img src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img src="themes/rainy_day/images/button1_r1_c1.gif" width="5" height="25" border="0" alt="" /></td> <td style="background-image:url(themes/rainy_day/images/button1_r1_c2.gif)"> <a href="{HREF_TGT}" title="{HREF_TITLE}">{HREF_LNK}</a> </td> <td><img src="themes/rainy_day/images/button1_r1_c3.gif" width="5" height="25" border="0" alt="" /></td> <!-- END {BLOCK_ID} --> EOT;
Define 'THEME_HAS_NO_SYS_MENU_BUTTONS' and include a "$template_sys_menu" template.
Insert this define
define('THEME_HAS_NO_SYS_MENU_BUTTONS', 1);
Copy the correct portion of "$template_main_menu" or "$template_main_menu1" from your theme.old.php as in this example from "Hardwired"
Verify that your template includes all of the following {TOKENS}, and rename the template to "$template_sys_menu"
// HTML template for sys menu $template_sys_menu = <<<EOT <table border="0" cellpadding="0" cellspacing="0"> <tr> <!-- BEGIN home --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleftmy" src="themes/hardwired/images/buttonleftmy.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{HOME_TGT}" title="{HOME_TITLE}">{HOME_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END home --> <!-- BEGIN my_gallery --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleftmy" src="themes/hardwired/images/buttonleftmy.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{MY_GAL_TGT}" title="{MY_GAL_TITLE}">{MY_GAL_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END my_gallery --> <!-- BEGIN allow_memberlist --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft" src="themes/hardwired/images/buttonleftmemb.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{MEMBERLIST_TGT}" title="{MEMBERLIST_TITLE}">{MEMBERLIST_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END allow_memberlist --> <!-- BEGIN my_profile --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft" src="themes/hardwired/images/buttonleft.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{MY_PROF_TGT}" title="{MY_PROF_LNK}">{MY_PROF_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END my_profile --> <!-- BEGIN faq --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft" src="themes/hardwired/images/buttonleftfaq.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{FAQ_TGT}" title="{FAQ_TITLE}">{FAQ_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END faq --> <!-- BEGIN enter_admin_mode --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleftad" src="themes/hardwired/images/buttonleftad.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{ADM_MODE_TGT}" title="{ADM_MODE_TITLE}">{ADM_MODE_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END enter_admin_mode --> <!-- BEGIN leave_admin_mode --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleftad" src="themes/hardwired/images/buttonleftad.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{USR_MODE_TGT}" title="{USR_MODE_TITLE}">{USR_MODE_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END leave_admin_mode --> <!-- BEGIN upload_pic --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleftup" src="themes/hardwired/images/buttonleftup.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{UPL_PIC_TGT}" title="{UPL_PIC_TITLE}">{UPL_PIC_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END upload_pic --> <!-- BEGIN register --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft" src="themes/hardwired/images/buttonleft.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{REGISTER_TGT}" title="{REGISTER_TITLE}">{REGISTER_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END register --> <!-- BEGIN login --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft" src="themes/hardwired/images/buttonleft.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{LOGIN_TGT}" title="{LOGIN_LNK}">{LOGIN_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END login --> <!-- BEGIN logout --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleftout" src="themes/hardwired/images/buttonleftout.gif" width="17" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{LOGOUT_TGT}" title="{LOGOUT_LNK}">{LOGOUT_LNK}</a> </td> <td><img name="buttonright" src="themes/hardwired/images/buttonright.gif" width="7" height="25" border="0" alt="" /></td> <!-- END logout --> </tr> </table> EOT;
Define 'THEME_HAS_NO_SUB_MENU_BUTTONS' and include a "$template_sys_menu" template.
Insert this define
define('THEME_HAS_NO_SUB_MENU_BUTTONS', 1);
Copy the correct portion of "$template_main_menu" or "$template_main_menu2" from your theme.old.php as in this example from "Hardwired"
Verify that your template includes all of the following {TOKENS}, and rename the template to "$template_sub_menu"
// HTML template for sub menu $template_sub_menu = <<<EOT <table border="0" cellpadding="0" cellspacing="0"> <tr> <!-- BEGIN custom_link --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft1" src="themes/hardwired/images/buttonleft1.gif" width="7" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{CUSTOM_LNK_TGT}" title="{CUSTOM_LNK_TITLE}">{CUSTOM_LNK_LNK}</a> </td> <td><img name="buttonright1" src="themes/hardwired/images/buttonright1.gif" width="7" height="25" border="0" alt="" /></td> <!-- END custom_link --> <!-- BEGIN album_list --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft1" src="themes/hardwired/images/buttonleft1.gif" width="7" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{ALB_LIST_TGT}" title="{ALB_LIST_TITLE}">{ALB_LIST_LNK}</a> </td> <td><img name="buttonright1" src="themes/hardwired/images/buttonright1.gif" width="7" height="25" border="0" alt="" /></td> <!-- END album_list --> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft1" src="themes/hardwired/images/buttonleft1.gif" width="7" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{LASTUP_TGT}" title="{LASTUP_LNK}">{LASTUP_LNK}</a> </td> <td><img name="buttonright1" src="themes/hardwired/images/buttonright1.gif" width="7" height="25" border="0" alt="" /></td> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft1" src="themes/hardwired/images/buttonleft1.gif" width="7" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{LASTCOM_TGT}" title="{LASTCOM_LNK}">{LASTCOM_LNK}</a> </td> <td><img name="buttonright1" src="themes/hardwired/images/buttonright1.gif" width="7" height="25" border="0" alt="" /></td> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft1" src="themes/hardwired/images/buttonleft1.gif" width="7" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{TOPN_TGT}" title="{TOPN_LNK}">{TOPN_LNK}</a> </td> <td><img name="buttonright1" src="themes/hardwired/images/buttonright1.gif" width="7" height="25" border="0" alt="" /></td> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft1" src="themes/hardwired/images/buttonleft1.gif" width="7" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{TOPRATED_TGT}" title="{TOPRATED_LNK}">{TOPRATED_LNK}</a> </td> <td><img name="buttonright1" src="themes/hardwired/images/buttonright1.gif" width="7" height="25" border="0" alt="" /></td> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft1" src="themes/hardwired/images/buttonleft1.gif" width="7" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{FAV_TGT}" title="{FAV_LNK}">{FAV_LNK}</a> </td> <td><img name="buttonright1" src="themes/hardwired/images/buttonright1.gif" width="7" height="25" border="0" alt="" /></td> <td><img name="spacer" src="images/spacer.gif" width="5" height="25" border="0" alt="" /></td> <td><img name="buttonleft1" src="themes/hardwired/images/buttonleft1.gif" width="7" height="25" border="0" alt="" /></td> <td style="background: url(themes/hardwired/images/buttoncenter.gif);"> <a href="{SEARCH_TGT}" title="{SEARCH_LNK}">{SEARCH_LNK}</a> </td> <td><img name="buttonright1" src="themes/hardwired/images/buttonright1.gif" width="7" height="25" border="0" alt="" /></td> </tr> </table> EOT;
Take stock of what you have so far, test your theme.
Insert into your theme.php and modify to suit
// Function to start a 'standard' table function starttable($width = '-1', $title = '', $title_colspan = '1') { global $CONFIG; if ($width == '-1') $width = $CONFIG['picture_table_width']; if ($width == '100%') $width = $CONFIG['main_table_width']; if ($title) { echo <<<EOT <!-- Start standard table title --> <table align="center" width="$width" cellspacing="0" cellpadding="0" class="maintablea"> <tr> <td> <table width="100%" cellspacing="0" cellpadding="0" class="tableh1a"> <tr> <td class="tableh1a"><img src="themes/mac_ox_x/images/tableh1a_bg_left.gif" alt="" /></td> <td class="tableh1a" style="background-image:url(themes/mac_ox_x/images/tableh1a_bg_middle.gif);" width="100%">$title</td> <td class="tableh1a"><img src="themes/mac_ox_x/images/tableh1a_bg_right.gif" alt="" /></td> </tr> </table> </td> </tr> </table> <!-- Start standard table --> <table align="center" width="$width" cellspacing="0" cellpadding="0"> <tr> <td style="background-image:url(themes/mac_ox_x/images/main_table_r1_c1b.gif);" valign="top"><img name="main_table_r1_c1" src="themes/mac_ox_x/images/main_table_r1_c1.gif" border="0" alt="" /></td> <td width="100%"><table width="100%" cellspacing="1" cellpadding="0" class="maintableb"> EOT; } else { echo <<<EOT <!-- Start standard table --> <table align="center" width="$width" cellspacing="0" cellpadding="0"> <tr> <td style="background-image:url(themes/mac_ox_x/images/main_table_r1_c1b.gif);" valign="top"><img name="main_table_r1_c1" src="themes/mac_ox_x/images/main_table_r1_c1.gif" border="0" alt="" /></td> <td width="100%"><table width="100%" cellspacing="1" cellpadding="0" class="cpg_zebra"> EOT; } } function endtable() { echo <<<EOT </table> </td> <td style="background-image:url(themes/mac_ox_x/images/main_table_r1_c3b.gif);" valign="top"><img name="main_table_r1_c3" src="themes/mac_ox_x/images/main_table_r1_c3.gif" border="0" alt="" /></td> </tr> <tr> <td><img name="main_table_r2_c1" src="themes/mac_ox_x/images/main_table_r2_c1.gif" width="10" height="4" border="0" alt="" /></td> <td style="background-image:url(themes/mac_ox_x/images/main_table_r2_c2b.gif);"><img name="main_table_r2_c2" src="themes/mac_ox_x/images/main_table_r2_c2.gif" border="0" alt="" /></td> <td><img name="main_table_r2_c3" src="themes/mac_ox_x/images/main_table_r2_c3.gif" width="10" height="4" border="0" alt="" /></td> </tr> </table> <!-- End standard table --> EOT; }
You can use this example also from "MAC_OX_X" to correct it.
Insert into your theme.php and modify to suit
// HTML template for title row of the thumbnail view (album title + sort options) $template_thumb_view_title_row = <<<EOT <table width="100%" cellpadding="0" cellspacing="0"> <tr> <td width="100%" class="statlink">{ALBUM_NAME}</td> <td class="sortorder_options" style="font-size: 100%;">{TITLE}</td> <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="thumbnails.php?album={AID}&page={PAGE}&sort=ta" title="{SORT_TA}"> + </a></span></td> <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="thumbnails.php?album={AID}&page={PAGE}&sort=td" title="{SORT_TD}"> - </a></span></td> <td> </td> <td class="sortorder_options" style="font-size: 100%;">{NAME}</td> <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="thumbnails.php?album={AID}&page={PAGE}&sort=na" title="{SORT_NA}"> + </a></span></td> <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="thumbnails.php?album={AID}&page={PAGE}&sort=nd" title="{SORT_ND}"> - </a></span></td> <td> </td> <td class="sortorder_options" style="font-size: 100%;">{DATE}</td> <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="thumbnails.php?album={AID}&page={PAGE}&sort=da" title="{SORT_DA}"> + </a></span></td> <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="thumbnails.php?album={AID}&page={PAGE}&sort=dd" title="{SORT_DD}"> - </a></span></td> <td> </td> <td class="sortorder_options" style="font-size: 100%;">{POSITION}</td> <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="thumbnails.php?album={AID}&page={PAGE}&sort=pa" title="{SORT_PA}"> + </a></span></td> <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="thumbnails.php?album={AID}&page={PAGE}&sort=pd" title="{SORT_PD}"> - </a></span></td> </tr> </table> EOT;
Find all instances of:
$template_display_picture
Replace all with:
$template_display_media
Find:
<td align="center" class="tableb" nowrap="nowrap">
Replace with:
<td align="center" class="display_media" nowrap="nowrap">
Find:
<!-- BEGIN catrow_noalb -->
<tr>
<td class="tableh2" colspan="3"><table border="0"><tr><td align="left">{CAT_THUMB}</td><td align="left"><span class="catlink"><b>{CAT_TITLE}</b></span>{CAT_DESC}</td></tr></table></td>
</tr>
<!-- END catrow_noalb -->
Replace with :
<!-- 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"><b>{CAT_TITLE}</b></span>{CAT_DESC}</td></tr></table></td>
</tr>
<!-- END catrow_noalb -->
Find:
<!-- BEGIN catrow -->
<tr>
<td class="tableb" align="left"><table border="0"><tr><td>{CAT_THUMB}</td><td><span class="catlink"><b>{CAT_TITLE}</b></span>{CAT_DESC}</td></tr></table></td>
<td class="tableb" align="center">{ALB_COUNT}</td>
<td class="tableb" align="center">{PIC_COUNT}</td>
</tr>
<tr>
<td class="tableb" colspan="3">{CAT_ALBUMS}</td>
</tr>
<!-- END catrow -->
Replace with :
<!-- BEGIN catrow -->
<tr>
<td class="catrow" align="left"><table border="0"><tr><td>{CAT_THUMB}</td><td><span class="catlink"><b>{CAT_TITLE}</b></span>{CAT_DESC}</td></tr></table></td>
<td class="catrow" align="center">{ALB_COUNT}</td>
<td class="catrow" align="center">{PIC_COUNT}</td>
</tr>
<tr>
<td class="tableb" colspan="3">{CAT_ALBUMS}</td>
</tr>
<!-- END catrow -->
Take stock of what you have so far, test your theme.
The "sample" theme found in themes/sample is designed to be a showcase for every themeable function and template used in Coppermine.
"Hardwired", "Eyeball", and "MAC_OX_X" are all good examples of more complicated theme designs that you can use as reference in continuing to modify your theme.
Now that you have a functioning "style.css", "template.html" and "theme.php" you should verify that it is generating valid output.
Each of the following pages needs to be validated as an anonymous user, registered user, and in admin mode:
The following toolbars can assist you in validating the resulting output of your theme:
Internet Explorer:
Mozilla Firefox:
Your theme should now be ready to use with Coppermine 1.4.x