Welcome to Geeklog, Anonymous Sunday, December 22 2024 @ 07:52 pm EST
Geeklog Forums
Custom Menus question
athertop
Anonymous
Since upgrading to 1.3.11 I have been playing around with the custom menus feature but cant get them to display at all. I have enabled them in config.php as can be seen below:
$_CONF['menu_elements'] = array
(
'home', // link to homepage
'contribute', // contribute / "submit a story" link
'links', // link to the links section (aka web resources)
'polls', // link to past polls
'calendar', // link to the site calendar
'search', // link to advanced search
'stats', // link to site stats
// 'prefs', // link to user's preferences
// 'plugins', // links added by plugins, like {plg_menu_elements}
'custom' // for custom links (see lib-custom.php)
);
I have amended the lib-custom.php as follows:
function CUSTOM_menuEntries ()
{
global $_CONF, $_USER;
$myentries = array ();
// 3 links
$myentries[] = array ('url' => $_CONF['site_url'] . '/gallery/index.php', 'label' => 'Gallery');
$myentries[] = array ('url' => $_CONF['site_url'] . '/forum/index.php', 'label' => 'Forum');
$myentries[] = array ('url' => $_CONF['site_url'] . '/userlist.php', 'label' => 'WhatCanIDoToday Members');
return $myentries;
}
And my header.thtml is using the {menu_elements} reserved word/variable.
Any ideas?
Thx in adv once again, paul
$_CONF['menu_elements'] = array
(
'home', // link to homepage
'contribute', // contribute / "submit a story" link
'links', // link to the links section (aka web resources)
'polls', // link to past polls
'calendar', // link to the site calendar
'search', // link to advanced search
'stats', // link to site stats
// 'prefs', // link to user's preferences
// 'plugins', // links added by plugins, like {plg_menu_elements}
'custom' // for custom links (see lib-custom.php)
);
I have amended the lib-custom.php as follows:
function CUSTOM_menuEntries ()
{
global $_CONF, $_USER;
$myentries = array ();
// 3 links
$myentries[] = array ('url' => $_CONF['site_url'] . '/gallery/index.php', 'label' => 'Gallery');
$myentries[] = array ('url' => $_CONF['site_url'] . '/forum/index.php', 'label' => 'Forum');
$myentries[] = array ('url' => $_CONF['site_url'] . '/userlist.php', 'label' => 'WhatCanIDoToday Members');
return $myentries;
}
And my header.thtml is using the {menu_elements} reserved word/variable.
Any ideas?
Thx in adv once again, paul
6
8
Quote
Status: offline
Dirk
Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Did you notice that the CUSTOM_menuEntries function is actually commented out in lib-custom.php? Did you remove the opening and closing comment markers before and after that function?
bye, Dirk
bye, Dirk
10
9
Quote
athertop
Anonymous
Dirk,
Doh! Missed the comments! Thanks, this worked fine. I need to brush up on my php though I think!
Thanks a lot, Paul
Doh! Missed the comments! Thanks, this worked fine. I need to brush up on my php though I think!
Thanks a lot, Paul
7
9
Quote
All times are EST. The time is now 07:52 pm.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content