navigation.tpl 4.48 KB
Newer Older
Evonne Cheung's avatar
Evonne Cheung committed
1

2

3
{if $MAINNAV}
Evonne Cheung's avatar
Evonne Cheung committed
4
5
6
        <div id="main-nav" class="{if $ADMIN || $INSTITUTIONALADMIN || $STAFF || $INSTITUTIONALSTAFF}{if $DROPDOWNMENU}dropdown-adminnav {else}adminnav {/if}{/if}main-nav">
            <ul id="{if $DROPDOWNMENU}dropdown-nav{else}nav{/if}">
{strip}
7
{foreach from=$MAINNAV item=item}
8
                <li class="{if $item.path}{$item.path}{else}dashboard{/if}{if $item.selected} selected{/if}{if $DROPDOWNMENU} dropdown-nav-home{/if}"><span><a href="{if $item.wwwroot}{$item.wwwroot}{else}{$WWWROOT}{/if}{$item.url}"{if $item.accesskey} accesskey="{$item.accesskey}"{/if} class="{if $item.path}{$item.path}{else}dashboard{/if}">{if $item.accessibletitle && !$DROPDOWNMENU}<span aria-hidden="true" role="presentation">{/if}{$item.title}{if $item.accessibletitle && !$DROPDOWNMENU}</span> <span class="accessible-hidden">({$item.accessibletitle})</span>{/if}{if $DROPDOWNMENU && $item.submenu} <span class="accessible-hidden">({str tag=dropdownmenu})</span>{/if}</a></span>
Evonne Cheung's avatar
Evonne Cheung committed
9
10
11
12
{if $DROPDOWNMENU}{if $item.submenu}
                    <ul class="dropdown-sub">
{strip}
{foreach from=$item.submenu item=subitem}
13
                        <li class="{if $subitem.selected}selected {/if}{if $subitem.submenu}has-sub {/if}"><span>
14
                            <a href="{if $item.wwwroot}{$item.wwwroot}{else}{$WWWROOT}{/if}{$subitem.url}"{if $subitem.accesskey} accesskey="{$subitem.accesskey}"{/if}>{$subitem.title}</a>
15
16
17
18
19
                        </span>
                        {if $subitem.submenu}
                            <ul class="dropdown-tertiary">
                                {foreach from=$subitem.submenu item=tertiaryitem}
                                    <li{if $tertiaryitem.selected} class="selected"{/if}><span>
20
                                        <a href="{if $item.wwwroot}{$item.wwwroot}{else}{$WWWROOT}{/if}{$tertiaryitem.url}"{if $tertiaryitem.accesskey} accesskey="{$tertiaryitem.accesskey}"{/if}>{$tertiaryitem.title}</a>
21
22
23
24
25
                                    </span></li>
                                {/foreach}
                            </ul>
                        {/if}
                        </li>
Evonne Cheung's avatar
Evonne Cheung committed
26
27
28
29
30
31
{/foreach}
{/strip}
                        <div class="cl"></div>
                    </ul>
{/if}{/if}
                </li>
32
{/foreach}
33
{if $ADMIN || $INSTITUTIONALADMIN || $STAFF || $INSTITUTIONALSTAFF}
34
                <li class="returntosite"><span><a href="{$WWWROOT}" accesskey="h" class="return-site">{str tag="returntosite"}</a></span></li>
Evonne Cheung's avatar
Evonne Cheung committed
35
{elseif $USER->get('admin')}
36
                <li class="siteadmin"><span><a href="{$WWWROOT}admin/" accesskey="a" class="admin-site">{str tag="administration"}</a></span></li>
Evonne Cheung's avatar
Evonne Cheung committed
37
{elseif $USER->is_institutional_admin()}
38
                <li class="instituteadmin"><span><a href="{$WWWROOT}admin/users/search.php" accesskey="a" class="admin-user">{str tag="administration"}</a></span></li>
39
{elseif $USER->get('staff')}
Evonne Cheung's avatar
Evonne Cheung committed
40
                <li class="siteinfo"><span><a href="{$WWWROOT}admin/users/search.php" accesskey="a" class="admin-user">{str tag="siteinformation"}</a></span></li>
41
{elseif $USER->is_institutional_staff()}
Evonne Cheung's avatar
Evonne Cheung committed
42
                <li class="instituteinfo"><span><a href="{$WWWROOT}admin/users/search.php" accesskey="a" class="admin-user">{str tag="institutioninformation"}</a></span></li>
43
44
{/if}
            {/strip}</ul>
45

Evonne Cheung's avatar
Evonne Cheung committed
46
47
48
        </div>
{if $DROPDOWNMENU}
{else}
49
        <div id="sub-nav">
50
{if $SELECTEDSUBNAV}
Evonne Cheung's avatar
Evonne Cheung committed
51
52
            <ul>
{strip}
53
{foreach from=$SELECTEDSUBNAV item=item}
54
                <li{if $item.selected} class="selected"{/if}><span><a href="{if $item.wwwroot}{$item.wwwroot}{else}{$WWWROOT}{/if}{$item.url}"{if $item.accesskey} accesskey="{$item.accesskey}"{/if}>{$item.title}</a></span></li>
55
56
57
                {if $item.submenu && $item.selected}
                {assign var=tertiarymenu value=$item.submenu}
                {/if}
58
59
60
{/foreach}
            {/strip}</ul>
{/if}
Evonne Cheung's avatar
Evonne Cheung committed
61
            <div class="cb"></div>
62
63
64
65
66
67
            </div>
            {if $tertiarymenu}
                <div id="tertiary-nav">
                    <ul>{strip}
                    {foreach from=$tertiarymenu item=tertiaryitem}
                        <li{if $tertiaryitem.selected} class="selected"{/if}><span>
68
                            <a href="{if $item.wwwroot}{$item.wwwroot}{else}{$WWWROOT}{/if}{$tertiaryitem.url}"{if $tertiaryitem.accesskey} accesskey="{$tertiaryitem.accesskey}"{/if}>{$tertiaryitem.title}</a>
69
70
71
72
73
74
                        </span></li>
                    {/foreach}
                    {/strip}</ul>
            <div class="cb"></div>
            </div>
            {/if}
75
{/if}
Evonne Cheung's avatar
Evonne Cheung committed
76
{/if}