{template 'header.html'}
<div class="cbanner row" style="height:{get('cslide_height')}px;">
	<div class="cbanner-bg">
		<div class="container">
			<div class="cbanner-title">
				<h4 class="column-title">
					{if count($articles)<=0}
					{lang('no_search_results')}	[ {$keyword} ]
					{else}
					[ {$keyword} ]{lang('searchresults')}
					{/if}
				</h4>
			</div>
		</div>
	</div>
</div>
<!-- 内页随机图片 -->
<script type="text/javascript">
    //<!CDATA[
    var bodyBgs = [];
    bodyBgs[0] = "{get('cslide_pic1')}";
    bodyBgs[1] = "{get('cslide_pic2')}";
    bodyBgs[2] = "{get('cslide_pic3')}";
    bodyBgs[3] = "{get('cslide_pic4')}";
    bodyBgs[4] = "{get('cslide_pic5')}";
    var randomBgIndex = Math.round( Math.random() * 4 );
    //输出随机的背景图
    document.write('<style>.cbanner{background:url(' + bodyBgs[randomBgIndex] + ') no-repeat 50% bottom;background-size:cover;}</style>');
    //]]>
</script>
<!-- 中部开始 -->
<div class="container list-container">
	<div class="blank30"></div>
	<!-- 面包屑导航开始 -->
	{template 'position.html'}
	<!-- 面包屑导航结束 -->
	<div class="row column">
		<div class="col-md-9 clo-xs-12">
			{if count($articles)<=0}
			<div class="blank30"></div>
			<div class="blank30"></div>
			<div class="text-center">
				<h2>{lang('no_search_results')}</h2>
			</div>
			<div class="blank30"></div>
			<div class="blank30"></div>
			{else}
			<!-- 内容列表开始 -->
			<div class="blank30"></div>
			<div class="column-list-text">
				{loop $articles $article}
				{cb_data($article)}
				<div class="column-list-text-item">
					<div class="column-list-text-date">
						<span>
							{=sdate($article['adddate'],'d')}
						</span>
						<p>
							{=sdate($article['adddate'],'Y-m')}
						</p>
					</div>
					<div class="column-list-text-text">
						<h4>
							<a title="{$article['stitle']}" href="{$article['url']}" >
								<?php if($keyword) echo str_replace($keyword,"<font style=color:red;font-weight:bold;>$keyword</font>",$article['title']); else { ?>{$article['title']}<?php } ?>
							</a>
						</h4>
						<p>
							{cut(strip_tags($article['introduce']),66)}
						</p>
					</div>
				</div>
				{/loop}
			</div>
			<!-- 内容列表结束 -->
			<!-- 内容列表分页开始 -->
			<div class="column-pagination">
				{if isset($record_count)} {search_pagination($page,$record_count)} {/if}
			</div>
			{/if}
		</div>
		<div class="col-md-3 clo-xs-12">
			<div class="blank30"></div>
			<div class="title20">
				<p>
					Retrieval condition
				</p>
				<h4>
					{lang('search_by_time')}
				</h4>
			</div>
			<div class="search-by-time">
				<button class="btn btn-default" type="button"  onclick="window.location.href ='{url('archive/search/keyword/'.$keyword)}&searchtype=0';" {if $searchtype==0 || !$searchtype } action {/if}>
				{lang('all_time')}
				</button>
				<button class="btn btn-default" type="button"  onclick="window.location.href ='{url('archive/search/keyword/'.$keyword)}&searchtype=3';" {if $searchtype==3 } action {/if}>
				{lang('this_year')}
				</button>
				<button class="btn btn-default" type="button"  onclick="window.location.href ='{url('archive/search/keyword/'.$keyword)}&searchtype=2';" {if $searchtype==2 } action {/if}>
				{lang('this_month')}
				</button>
				<button class="btn btn-default" type="button"  onclick="window.location.href ='{url('archive/search/keyword/'.$keyword)}&searchtype=1';" {if $searchtype==1 } action {/if}>
				{lang('this_week')}
				</button>
			</div>
		</div>
	</div>
	<div class="blank30"></div>
	<!-- 内容列表分页结束 -->
</div>
<div class="blank30"></div>
{template 'footer.html'}