westdc-zf1/application/default/views/scripts/water/search.phtml

57 lines
2.3 KiB
PHTML
Raw Normal View History

2010-06-23 15:13:26 +00:00
<?php
$this->headTitle($this->config->title->site);
$this->headTitle($this->config->title->data);
$this->headTitle('快速搜索');
if (!empty($this->codename)) $this->headTitle($this->codename);
$this->headTitle()->setSeparator(' - ');
$this->headLink()->appendStylesheet('/css/water.css');
2010-06-23 15:13:26 +00:00
$this->breadcrumb('<a href="/">首页</a>');
$this->breadcrumb('<a href="/data">'.$this->config->title->data.'</a>');
$this->breadcrumb('<a href="/water/">黑河综合遥感联合试验</a>');
2010-06-23 15:13:26 +00:00
$this->breadcrumb('快速搜索');
$this->breadcrumb()->setSeparator(' > ');
?>
2013-04-16 06:24:09 +00:00
<div class="tools row">
<ul><form id="search" enctype="application/x-www-form-urlencoded" action="/water/search" method="post">
<li><input type="text" name="q" id="q" value="输入关键词搜索标题和摘要" onfocus="myfocus(this);" onblur="myblur(this);"></li>
<li><button type="submit" name="submit" id="submit">搜索</button></li>
<li><button type="button" onclick="location.href='/water/tag'">关键词导航</button></li>
<li><button type="button" onclick="location.href='/water/timeline'">时间轴导航</button></li>
<li><button type="button" onclick="location.href='/water/timemap'">时空联合导航</button></li>
</form></ul>
<script>
function myfocus(element) {
if (element.value == element.defaultValue) {
element.value = '';
}
}
function myblur(element) {
if (element.value == '') {
element.value = element.defaultValue;
}
}
</script>
</div>
2010-06-23 15:13:26 +00:00
<?php if (!empty($this->metadata)) : ?>
<?php echo $this->page->getNavigation();
foreach($this->metadata as $md) : ?>
2013-04-16 06:24:09 +00:00
<div class="media well well-small">
<a class="pull-left" href="#">
<img class="media-object" src="/service/thumb/id/<?php echo $md['id'];?>" data-src="holder.js/128x128">
</a>
<div class="media-body">
<h4 class="media-heading"><a href="/data/<?php echo $md['uuid'];?>"><?php echo $this->escape($md['title']);?></a></h4>
<div class="summary"><?php echo str_replace(array("\r\n", "\n", "\r"),'<br />',mb_strlen($md['description'])>400?$this->escape(mb_substr($md['description'],0,400,'UTF-8').'...'):$this->escape($md['description']));?></div>
</div>
2010-06-23 15:13:26 +00:00
</div>
<?php endforeach; ?>
<hr class="mditem" />
<?php echo $this->page->getNavigation();
else :
?>
<div class="mditem">
2010-06-23 15:13:26 +00:00
<hr />
您的搜索结果为空,请尝试缩小关键词进行查询。
</div>
2010-06-23 15:13:26 +00:00
<?php endif; ?>