Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Moving SYS_MENU to right side nav  (Read 2371 times)

0 Members and 1 Guest are viewing this topic.

Gephri

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 235
Moving SYS_MENU to right side nav
« on: March 01, 2007, 09:29:35 am »

I have a fully functioning right side navigation panel set up through template.html.
How can I move the SYS_MENU variable from near the top of the page to this new location?  When I try it I just get {SUB_MENU} showing - and any plugins linked to it.

Thanks
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Moving SYS_MENU to right side nav
« Reply #1 on: March 01, 2007, 10:18:59 am »

{SUB_MENU}, {SYS_MENU} and {ADMIN_MENU} are defined in the pageheader. If they come after the {GALLERY}-token (which is the separator between the pageheader and pagefooter in terms of Coppermine's template system), you'll have to remove it from the pageheader and move it to the pagefooter instead.
Logged

zac

  • Contributor
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 153
Re: Moving SYS_MENU to right side nav
« Reply #2 on: March 11, 2007, 05:17:14 am »

I just needed to do the same thing thanks for pointing the way Gau Gau..  to further clarify for anyone ...

This is all I moved and it seems to work great: 
Code: [Select]
'{SUB_MENU}' => theme_main_menu('sub_menu'),
here is all the altered code copied into my theme.php


Code: [Select]

// Function for writing a pageheader

function pageheader($section, $meta = '')

{

    global $CONFIG, $THEME_DIR;

    global $template_header, $lang_charset, $lang_text_dir;



    $custom_header = cpg_get_custom_include($CONFIG['custom_header_path']);



        $charset = ($CONFIG['charset'] == 'language file') ? $lang_charset : $CONFIG['charset'];



    header('P3P: CP="CAO DSP COR CURa ADMa DEVa OUR IND PHY ONL UNI COM NAV INT DEM PRE"');

        header("Content-Type: text/html; charset=$charset");

    user_save_profile();



    $template_vars = array('{LANG_DIR}' => $lang_text_dir,

        '{TITLE}' => $CONFIG['gallery_name'] . ' - ' . strip_tags(bb_decode($section)),

        '{CHARSET}' => $charset,

        '{META}' => $meta,

        '{GAL_NAME}' => $CONFIG['gallery_name'],

        '{GAL_DESCRIPTION}' => $CONFIG['gallery_description'],

        '{SYS_MENU}' => theme_main_menu('sys_menu'),

       

        '{ADMIN_MENU}' => theme_admin_mode_menu(),

        '{CUSTOM_HEADER}' => $custom_header,

        );



    echo template_eval($template_header, $template_vars);

}



// Function for writing a pagefooter

function pagefooter()

{

    //global $HTTP_GET_VARS, $HTTP_POST_VARS, $HTTP_SERVER_VARS;

    global $USER, $USER_DATA, $ALBUM_SET, $CONFIG, $time_start, $query_stats, $queries;;

    global $template_footer;



    $custom_footer = cpg_get_custom_include($CONFIG['custom_footer_path']);



    if ($CONFIG['debug_mode']==1 || ($CONFIG['debug_mode']==2 && GALLERY_ADMIN_MODE)) {

    cpg_debug_output();

    }



    $template_vars = array(

        '{CUSTOM_FOOTER}' => $custom_footer,

'{SUB_MENU}' => theme_main_menu('sub_menu'),

        '{VANITY}' => (defined('THEME_IS_XHTML10_TRANSITIONAL') && $CONFIG['vanity_block']) ? theme_vanity() : '',

    );



    echo template_eval($template_footer, $template_vars);

}



// 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'];

    echo <<<EOT



<!-- Start standard table -->

<table align="center" width="$width" cellspacing="1" cellpadding="0" class="maintable">



EOT;

    if ($title) {

        echo <<<EOT

        <tr>

                <td class="tableh1" colspan="$title_colspan">$title</td>

        </tr>



EOT;

    }

}

Logged
Pages: [1]   Go Up
 

Page created in 0.016 seconds with 16 queries.