Revision [19045]

This is an old revision of DanWestCustomNav made by DanWest on 2008-01-28 00:14:01.

 

Custom Navigation Per Page

See Also
  • UserMenus - Menus defined by a suffix added to the page tag.
Last edited by DanWest:
Modified links pointing to docs server
Mon, 28 Jan 2008 00:14 UTC [diff]

What

Use
Example NavigationLinks page
:SomePage: [[HomePage Home]] [[PersonalPage My Page]] [[UserSettings User Settings]]
:AnotherPage: [[HomePage Home]] [[PersonalPage My Page]] [[SomePage Some Other Page]] [[UserSettings User Settings]]


Installation

Code
File: header.php
  1. $nav_page = $this->LoadPage('NavigationLinks');
  2. if(ereg(':' . $this->page['tag'] . ': ([^\n]*)\n', $nav_page['body'], $match)) {
  3.     echo $this->Format($match[1]));
  4. } else if ($this->GetUser()) {
  5.     echo $this->config['logged_in_navigation_links'] ? $this->Format($this->config['logged_in_navigation_links']).'' : '';
  6. } else {
  7.     echo $this->config['navigation_links'] ? $this->Format($this->config['navigation_links']) : '';
  8. }


To Do


CategoryUserContributions
There are no comments on this page.
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki