westdc-zf1/application/default/views/scripts/sanji-header.phtml

86 lines
3.7 KiB
PHTML
Raw Normal View History

<!--顶部导航-->
2018-06-22 08:59:07 +00:00
<div class="pageTitle">
<div class="container">
<div class="col-md-8" style="padding-left: 0;">
2018-06-23 13:11:31 +00:00
<img src="/static-sanjy-np/img/logo3_03.png" alt="" style="width: 75px;float: left;margin-right: 10px;"/>
<h5 >三江源国家公园星空地一体化生态监测数据平台</h5>
2018-07-17 02:54:51 +00:00
<span style="font-size: 16px">Ecological Data Center of Sanjiangyuan National Park</span>
2018-06-22 08:59:07 +00:00
</div>
<div class="col-md-4 searchBox" style="padding-right: 0;">
2018-06-24 05:12:14 +00:00
<form action="/search" id="search-form">
<i onclick="$('#search-form').submit()">搜索</i>
<input type="text" name="q" id="q" class="form-control" placeholder="请输入搜索内容">
</form>
2018-06-22 08:59:07 +00:00
</div>
</div>
</div>
<header class="header">
<div class="container">
2018-06-22 08:59:07 +00:00
<nav class="navbar navbar-default" role="navigation">
<div class="container-fluid" style="padding-left: 0;">
<div class="navbar-header">
2018-06-23 13:11:31 +00:00
<button type="button" class="navbar-toggle" data-toggle="collapse"
data-target="#example-navbar-collapse">
2018-06-22 08:59:07 +00:00
<span class="sr-only">切换导航</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<div class="collapse navbar-collapse" id="example-navbar-collapse" style="padding-left: 0;">
2018-07-26 02:41:22 +00:00
<ul id="main-menu" class="nav navbar-nav">
2018-06-22 08:59:07 +00:00
<li>
2018-07-26 03:10:29 +00:00
<a href="/index" class="">首页</a>
2018-06-22 08:59:07 +00:00
</li>
<li>
<a href="/data">数据服务</a>
</li>
2018-06-23 13:11:31 +00:00
<li>
2018-07-19 04:35:52 +00:00
<a href="/map">园区分布</a>
2018-06-23 13:11:31 +00:00
</li>
2018-07-18 09:56:59 +00:00
<li>
<a href="/observe">监测数据</a>
</li>
2018-06-22 08:59:07 +00:00
<li>
2018-06-22 09:39:31 +00:00
<a href="/archives/news/localnews">新闻动态</a>
2018-06-22 08:59:07 +00:00
</li>
<li>
2018-06-22 11:36:26 +00:00
<a href="/about">关于我们</a>
2018-06-22 08:59:07 +00:00
</li>
</ul>
2018-06-23 10:05:32 +00:00
2018-06-23 14:15:27 +00:00
<ul class="nav navbar-nav navbar-right">
<?php
$auth = Zend_Auth::getInstance();
if ($auth->hasIdentity()) {
$user = $auth->getIdentity();
echo '<li><a href="/account">' . $user->username . '</a></li>';
if ($user->usertype == "administrator") echo '<li><a href="/admin"><i class="icon-cog"></i>后台</a></li> ';
echo '<li><a href="/data/order"><i class="icon-shopping-cart"></i>数据篮</a></li> <li><a href="/account/logout">注销</a></li>';
} else {
echo '<a href="/account/register" id="register">注册</a><a href="/account/login" id="login">登录</a>';
} ?>
</ul>
2018-06-22 08:59:07 +00:00
</div>
</div>
2018-02-04 07:05:06 +00:00
</nav>
</div>
2018-07-26 02:41:22 +00:00
</header>
<!--nav selected style-->
<script>
$(document).ready(function () {
var url = window.location.pathname;
2018-07-26 06:04:14 +00:00
var url_arry = url.split('/');
2018-07-26 06:11:21 +00:00
if(url_arry[1] == ''){
url_arry[1] = 'index'
}
2018-07-26 06:04:14 +00:00
var select = "#main-menu li a[href ^= '/"+url_arry[1] + "']";
2018-07-26 03:10:29 +00:00
$(select).addClass("nav-active");
2018-07-26 02:41:22 +00:00
});
</script>