<?php if(!defined('IN_SDCMS')) exit;?>
<div class="offside offside-left" id="offside-nav">
	
	<form action="{N('search')}" method="get">
		<div class="form-group">
			<div class="input-group">
				{if !isempty(sdcms[pathinfo])&&sdcms[url_mode]>1}<input type="hidden" name="s" value="search{sdcms[url_ext]}" />{/if}
					{if sdcms[url_mode]==1}<input type="hidden" name="c" value="other" /><input type="hidden" name="a" value="search" />{/if}
				<input type="text" name="keyword" class="form-ip radius-right-none" placeholder="请输入关键字">
				<button type="submit" class="after"><div class="ui-icon-search"></div></button>
			</div>
		</div>
	</form>
	
	<div class="collapse-menu-title"><a href="{$webroot}" title="网站首页">网站首页</a></div>
	{sdcms:rp top="0" table="sd_category" where="followid=0 and isshow=1" order="catenum,cateid"}
	{php $sub_sonid=$rp[cateid]}
	{php $sub_num=get_sonid_num($rp[cateid])}
	<div class="collapse-menu-title {is_active($rp[cateid],$parentid,'active',1)}">
		<a href="{cateurl($rp[cateid])}" title="{$rp[catename]}">{$rp[catename]}</a>{if $sub_num>0}<i class="ui-icon-right"></i>{/if}
	</div>
	{if $sub_num>0}
	<div class="collapse-menu-body {is_active($rp[cateid],$parentid,'shows',1)}">
		<ul>
			{sdcms:rs top="0" table="sd_category" where="followid=$sub_sonid and isshow=1" order="catenum,cateid"}
			<li{is_active($rs[cateid],$parentid,'active')}><a href="{cateurl($rs[cateid])}" title="{$rs[catename]}"{if $rs[isblank]==1}{/if}><i class="ui-icon-square font-14 mr"></i>{$rs[catename]}</a></li>
			{/sdcms:rs}
		</ul>
	</div>
	{/if}
	{/sdcms:rp}
</div>