{/if}
|
{code}
|
|
+! Use Nexus |
+if you really don't want to create a menu by hand, you can (with some modifications of the files), use nexus. |
+first of all, create a menu using Nexus and pick the suckerfish horizontal dropdown menu style. this is the same as the one currently in use. if you don't like this menu, or you feel it is too buggy, you might have to create your own Nexus plugin (see the NexusPackage page for details). |
+ |
+once you have picked a name for the nexus menu and you have created a new menu, Nexus creates a cached file. you can now copy the cached file to the same folder as your top_bar.tpl file. |
+ |
+the file will look something like: |
+{code()} |
+{tikimodule title=...}<very hard to read menu stuff in here>{/tikimodule} |
+{code} |
+ |
+all you need to do now is remove everything in the first and last set of curly braces that you are left with the <very hard to read menu stuff>. |
+ |
+finally, you need to modify the top_bar.tpl file to include the file you just created in your top bar: |
+{code()} |
+ <this is where the custom menu goes> |
+changes to: |
+ { include file="bitpackage=kernel/<menu file name>.tpl"} |
+{code} |
+^__Note__: i had to insert a space between __{__ and __include__ due to the include plugin. please don't copy and paste the above without removing the space.^ |
+ |
+!! Custom Menu |
the custom menu is a simple XHTML unordered list with a few classes set for the links and looks something like this:
|
{code()}
|
-<ul id="nav" class="menu hor">
|
+<ul id="nav"> |
<li>
|
- <a class="head" href="/link/to/page">Foo</a>
|
+ <a href="/link/to/page">Foo</a> |
<ul>
|
- <li><a class="item" href="/link/to/page">Pile</a></li>
|
- <li><a class="item" href="/link/to/page">Of</a></li>
|
- <li><a class="item" href="/link/to/page">Foo</a></li>
|
+ <li><a href="/link/to/page">Pile</a></li> |
+ <li><a href="/link/to/page">Of</a></li> |
+ <li><a href="/link/to/page">Foo</a></li> |
</ul>
|
</li>
|
|
<li>
|
- <a class="head" href="/link/to/page">Bar</a>
|
+ <a href="/link/to/page">Bar</a> |
<ul>
|
- <li><a class="item" href="/link/to/page">Another</a></li>
|
- <li><a class="item" href="/link/to/page">Pile</a></li>
|
- <li><a class="item" href="/link/to/page">Of</a></li>
|
- <li><a class="item" href="/link/to/page">Foo</a></li>
|
+ <li><a href="/link/to/page">Another</a></li> |
+ <li><a href="/link/to/page">Pile</a></li> |
+ <li><a href="/link/to/page">Of</a></li> |
+ <li><a href="/link/to/page">Foo</a></li> |
</ul>
|
</li>
|
</ul>
|
{code}
|
|
+!! Final Code |
the resulting file should look something like this:
|
{code()}
|
{strip}
|
{* this link is for textbrowsers *}
|
<div id="bittopbar">
|
{if $gBitUser->isAdmin()}
|
- <a style="display:none;position:absolute;top:0px;left:0px;" href="#top">{tr}go to top{/tr}</a>
|
- <ul id="nav" class="menu hor">
|
- <li class="m-home"><a class="item" href="{$gBitLoc.BIT_ROOT_URL}">{tr}{$siteTitle|default:"Home"}{/tr}</a></li>
|
+ <a href="#top">{tr}go to top{/tr}</a> |
+ <ul id="nav"> |
+ <li><a href="{$gBitLoc.BIT_ROOT_URL}">{tr}{$siteTitle|default:"Home"}{/tr}</a></li> |
{foreach key=key item=menu from=$appMenu}
|
{if $menu.title && $menu.titleUrl && $menu.template}
|
- <li class="m-{$key}{if $gBitLoc.ACTIVE_PACKAGE eq $menu.adminPanel} current{/if}">
|
- <a class="{if $gBitSystemPrefs.feature_top_bar_dropdown eq 'y'}head{else}item{/if}{if $gBitLoc.ACTIVE_PACKAGE eq $menu.adminPanel} selected{/if}" href="{$menu.titleUrl}">{tr}{$menu.title}{/tr}</a>
|
+ <li> |
+ <a href="{$menu.titleUrl}">{tr}{$menu.title}{/tr}</a> |
{if $gBitSystemPrefs.feature_top_bar_dropdown eq 'y'}
|
{ include file="`$menu.template`"}
|
{/if}
|