Advanced search  


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.

Pages: [1]   Go Down

Author Topic: [Solved]: {Sys_menu} and {Sub_menu} don't show up  (Read 2921 times)

0 Members and 1 Guest are viewing this topic.


  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 24
[Solved]: {Sys_menu} and {Sub_menu} don't show up
« on: May 22, 2009, 08:30:37 pm »

I just created a template, but when I add the {Sys_menu} and {Sub_menu}, they don't show up in the gallery. They are shown as "{Sys_menu}" and "{Sub_menu}" literally. Here it is:

Hope someone can help me out!
« Last Edit: May 23, 2009, 05:14:34 pm by Joachim Müller »


  • Guest
Re: {Sys_menu} and {Sub_menu} don't show up
« Reply #1 on: May 22, 2009, 08:36:38 pm »

They need to appear before the {GALLERY} tag. Try rearranging your html.


  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 24
Re: {Sys_menu} and {Sub_menu} don't show up
« Reply #2 on: May 22, 2009, 09:06:14 pm »

Thank you :D

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
Re: {Sys_menu} and {Sub_menu} don't show up
« Reply #3 on: May 23, 2009, 05:14:18 pm »

Or try coming up with a "left-handed" theme: if the tokens for the menus must come after the {GALLERY}-token, they need to be defined withion the pagefooter function instead of the pageheader function. This is the case for example in the Chaoticsould theme - preview it here, download it here. Take a look how the menu is called there. Take particular notice of the file theme.php - this is the relevant code:
Code: [Select]
// Function for writing a pagefooter

function pagefooter()



    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)) {



    $template_vars = array(

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

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

        '{ADMIN_MENU}' => theme_admin_mode_menu(),

        '{CUSTOM_FOOTER}' => $custom_footer,

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


    echo template_eval($template_footer, $template_vars);

Pages: [1]   Go Up

Page created in 0.016 seconds with 19 queries.