Getting Started : Customizing Getting Started : Customizing
 

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

Getting Started : Customizing

Started by Cyco, January 27, 2005, 07:47:14 AM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

Cyco

Hi
I just installed the gallery. Which file should I modify to customize my site.? For example I need to "MyDomain.com" text on top & change coppermine logo to mysite's logo.

Thanks in advance

donnoman


Cyco

That askes to start by modifing theme.php under my theme. If I be more specific on my questions,
1)I know I can remove top menu item by commenting "<a href="{LASTUP_TGT}">{LASTUP_LNK}</a>" parts.
But how can I make it visible when loged as "admin" ?

2) How to temove the "myDomain.com" heading on top. I cant find any clue in theme.php

Thanks

Abbas Ali

Quote from: Cyco on January 27, 2005, 09:00:34 AM
1)I know I can remove top menu item by commenting "<a href="{LASTUP_TGT}">{LASTUP_LNK}</a>" parts.
But how can I make it visible when loged as "admin" ?

You will have to edit pageheader function in theme.php and apply condition to check whether the user is admin before building each menu.


if (GALLERY_ADMIN_MODE) {
  //code to build menu/link
}


Quote from: Cyco on January 27, 2005, 09:00:34 AM
2) How to temove the "myDomain.com" heading on top. I cant find any clue in theme.php

Look for it in template.html in theme folder.
Chief Geek at Ranium Systems

Joachim Müller

Quote from: Abbas Ali on January 27, 2005, 12:43:02 PM
You will have to edit pageheader function in theme.php and apply condition to check whether the user is admin before building each menu.
not quite, you can use the existing menus: edit themes/yourtheme/theme.php, find<a href="{LASTUP_TGT}">{LASTUP_LNK}</a> ::and replace with<!--<a href="{LASTUP_TGT}">{LASTUP_LNK}</a> ::-->
Next, find// HTML template for gallery admin menu
$template_gallery_admin_menu = <<<EOT

                <div align="center">
                <table cellpadding="0" cellspacing="1">
                        <tr>
and add after it<td class="admin_menu"><a href="{LASTUP_TGT}">{LASTUP_LNK}</a></td>Then, find    if (GALLERY_ADMIN_MODE) {
        $param = array('{CATL}' => $cat_l,
            '{UPL_APP_LNK}' => $lang_gallery_admin_menu['upl_app_lnk'],
            '{CONFIG_LNK}' => $lang_gallery_admin_menu['config_lnk'],
            '{ALBUMS_LNK}' => $lang_gallery_admin_menu['albums_lnk'],
            '{CATEGORIES_LNK}' => $lang_gallery_admin_menu['categories_lnk'],
            '{USERS_LNK}' => $lang_gallery_admin_menu['users_lnk'],
            '{GROUPS_LNK}' => $lang_gallery_admin_menu['groups_lnk'],
            '{COMMENTS_LNK}' => $lang_gallery_admin_menu['comments_lnk'],
            '{SEARCHNEW_LNK}' => $lang_gallery_admin_menu['searchnew_lnk'],
            '{MY_PROF_LNK}' => $lang_user_admin_menu['my_prof_lnk'],
            '{UTIL_LNK}' => $lang_gallery_admin_menu['util_lnk'],
            '{BAN_LNK}' => $lang_gallery_admin_menu['ban_lnk'],
            '{DB_ECARD_LNK}' => $lang_gallery_admin_menu['db_ecard_lnk'],
            );
and replace with    if (GALLERY_ADMIN_MODE) {
        $param = array('{CATL}' => $cat_l,
            '{UPL_APP_LNK}' => $lang_gallery_admin_menu['upl_app_lnk'],
            '{CONFIG_LNK}' => $lang_gallery_admin_menu['config_lnk'],
            '{ALBUMS_LNK}' => $lang_gallery_admin_menu['albums_lnk'],
            '{CATEGORIES_LNK}' => $lang_gallery_admin_menu['categories_lnk'],
            '{USERS_LNK}' => $lang_gallery_admin_menu['users_lnk'],
            '{GROUPS_LNK}' => $lang_gallery_admin_menu['groups_lnk'],
            '{COMMENTS_LNK}' => $lang_gallery_admin_menu['comments_lnk'],
            '{SEARCHNEW_LNK}' => $lang_gallery_admin_menu['searchnew_lnk'],
            '{MY_PROF_LNK}' => $lang_user_admin_menu['my_prof_lnk'],
            '{UTIL_LNK}' => $lang_gallery_admin_menu['util_lnk'],
            '{BAN_LNK}' => $lang_gallery_admin_menu['ban_lnk'],
            '{DB_ECARD_LNK}' => $lang_gallery_admin_menu['db_ecard_lnk'],
            '{LASTUP_TGT}' => "thumbnails.php?album=lastup$cat_l2",
            '{LASTUP_LNK}' => $lang_main_menu['lastup_lnk'],
            );

Save the file and upload it to your webserver. Make a backup of the file before modifying it, so you can savely go back if something goes wrong.

Joachim