<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="zh-CN" style="overflow-x:hidden;">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Language" content="zh-CN" />
<meta content="all" name="robots" />
<meta name="author" content="CmsEasy Team" />
<meta name="Copyright" content="2009-2011 CmsEasy Inc" />
<meta name="description" content="" />
<meta content="" name="keywords" />
<link rel="icon" href="{$base_url}/favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="{$base_url}/favicon.ico" type="image/x-icon" />
<title><?php echo get('sitename');?> - 后台管理中心</title>

<!-- 调用样式表 -->
<link href="{$skin_path}/admin.css" rel="stylesheet" type="text/css" />
<link title="skin1" href="{$skin_path}/admin_style_a.css" type="text/css" rel="alternate stylesheet" disabled />
<link title="skin2" href="{$skin_path}/admin_style_b.css" type="text/css" rel="stylesheet"/>
<link title="skin3" href="{$skin_path}/admin_style_c.css" type="text/css" rel="stylesheet"/>
<link title="skin4" href="{$skin_path}/admin_style_d.css" type="text/css" rel="stylesheet"/>
<link title="skin5" href="{$skin_path}/admin_style_e.css" type="text/css" rel="stylesheet"/>
<script type="text/javascript" language="javascript" src="{$skin_path}/js/styleswitcher.js"></script>

<script type="text/javascript" language="javascript" src="{$base_url}/js/script.js"></script>
<script type="text/javascript" src="{$base_url}/js/jquery.min.js"></script>
<script language="javascript" type="text/javascript" src="{$base_url}/js/admin.js"></script>

<script language='JavaScript'>
//去掉虚线框
function bluring(){
if(event.srcElement.tagName=="A"||event.srcElement.tagName=="IMG") document.body.focus();
}
document.onfocusin=bluring;
</script>


<script type="text/javascript">
//点击关闭提示信息层
function turnoff(obj){
document.getElementById(obj).style.display="none";
}

//省市区
$(document).ready(function() {
	$('#search_province_id').change(function(){
		$.ajax({
			url: '<?php echo url('area/city_option_search',false);?>',
			data:'province_id='+$(this).val(),
			type: 'POST',
			dataType: 'html',
			timeout: 1000,
			success: function(data){
				$('#search_city_id').html(data);
			}
		});
	});
	$('#search_city_id').change(function(){
		$.ajax({
			url: '<?php echo url('area/section_option_search',false);?>',
			data:'city_id='+$(this).val(),
			type: 'POST',
			dataType: 'html',
			timeout: 1000,
			success: function(data){
				$('#search_section_id').html(data);
			}
		});
	});
	$(document).ready(function() {
		$('#province_id').change(function(){
			$.ajax({
				url: '<?php echo url('area/city_option',false);?>',
				data:'province_id='+$(this).val(),
				type: 'POST',
				dataType: 'html',
				timeout: 1000,
				success: function(data){
					$('#city_id').html(data);
				}
			});
		});
		$('#city_id').change(function(){
			$.ajax({
				url: '<?php echo url('area/section_option',false);?>',
				data:'city_id='+$(this).val(),
				type: 'POST',
				dataType: 'html',
				timeout: 1000,
				success: function(data){
					$('#section_id').html(data);
				}
			});
		});
	});
});
</script>

<!--用于PNG图片在IE6下透明-->
<!--[if IE 6]>
<script type="text/javascript" language="javascript" src="{$base_url}/js/png.js"></script>
<script>
  DD_belatedPNG.fix('.logo');
  DD_belatedPNG.fix('#c'); 
  DD_belatedPNG.fix('.right'); 
  DD_belatedPNG.fix('#header'); 
  DD_belatedPNG.fix('#nav'); 
  DD_belatedPNG.fix('.nav li.on'); 
  DD_belatedPNG.fix('.nav li.on a'); 
  DD_belatedPNG.fix('#menu dd a'); 
  DD_belatedPNG.fix('.right_bottom'); 
  DD_belatedPNG.fix('.copy'); 

</script>
<![endif]--> 




</head>

<body class="slide slide3 s1">
<!-- 头部 -->
<div class="icons">
<a onclick="setActiveStyleSheet('skin1'); return false;" href="#"><img src="{$skin_path}/images/bg_2.gif" /></a>
<a onclick="setActiveStyleSheet('skin2'); return false;" href="#"><img src="{$skin_path}/images/bg_1.gif" /></a>
<a onclick="setActiveStyleSheet('skin3'); return false;" href="#"><img src="{$skin_path}/images/bg_3.gif" /></a>
<a onclick="setActiveStyleSheet('skin4'); return false;" href="#"><img src="{$skin_path}/images/bg_4.gif" /></a>
<a onclick="setActiveStyleSheet('skin5'); return false;" href="#"><img src="{$skin_path}/images/bg_5.gif" /></a>

</div> 

<div class="box">

<div id="header">

<a href=""><img src="{$skin_path}/images/logo.png" class="logo" /></a>

<div class="top_right">
<ul>
<li><span>您好，<strong>{$user.username}！</strong> [<a href="{$base_url}/index.php?case=index&act=logout&admin_dir={config::get('admin_dir')}">退出</a>]</span></li>
<li><a href="http://www.cmseasy.cn" target="_blank">官方网站</a> | <a href="http://www.cmseasy.cn/service_1.html" target="_blank">授权</a> | <a href="http://www.cmseasy.org" target="_blank">支持论坛</a> | <a href="http://chm.cmseasy.cn/" target="_blank">帮助？</a></li>
</ul>
</div>

</div>

<div id="nav">
<div class="nav_bg">
<div class="nav">
<ul>
<?php $menu=admin_menu::top(); ?>
{loop $menu $n $m}
<?php
preg_match('/mod=(\w+)&/is',$m,$m1);
$class = $m1[1] == session::get('mod')?'on':'no';
$m1[1] == session::get('mod')?session::set('modname',$n):'';
?>
<li class="{$class}"><a href="{$m}">{$n}</a></li>
{/loop}
</ul>

<select id="website" name="website" onchange="javascript:window.open(this.options[this.selectedIndex].value)">
<option value="default">默认站点管理</option>
{loop getwebsite() $d}
<option value="{$d[addr]}">{$d[name]}管理</option>
{/loop}
</select>

</div>
</div>
</div>



<div id="c">

<div id="left">

<div id="menu">


<?php $menu=admin_menu::get(); $i=0; $class1 = '';?>
<?php $menu=admin_menu::get(); $j=0; $class1 = '';?>
<?php $menu=admin_menu::get(); $k=0; $class1 = '';?>
{loop $menu $ns $ms}

<h5 class="h5_{=$i+1}">{$ns}</h5>
<dl class="l_{=$j+1}">
{if $ns != '系统信息'}


{loop $ms $n $m}
<?php
preg_match('/act=(\w+)&/is',$m,$m2);
preg_match('/table=(\w+)&/is',$m,$m3);
preg_match('/set=(\w+)&/is',$m,$m4);
preg_match('/tagfrom=(\w+)&/is',$m,$m5);
preg_match('/item=(\w+)&/is',$m,$m6);
preg_match('/needcheck=(\w+)&/is',$m,$m7);

if(front::get('case')=='config' && front::get('act')=='system' &&  $m4[1] == session::get('set')){
	session::set('actname',$n);
	$class1 = 'on';

}elseif($m2[1] == session::get('act') && $m3[1] == session::get('table') && session::get('table')!=''){
	session::set('actname',$n);
	$class1 = 'on';

}elseif(front::get('case')=='form' && $m2[1] == session::get('act')){
	session::set('actname',$n);
	$class1 = 'on';

}elseif(front::get('case')=='template' && $m2[1] == session::get('act')){
	session::set('actname',$n);
	$class1 = 'on';

}elseif(front::get('case')=='index' && front::get('act')=='index' && front::get('mod')==''){
	session::set('actname','首页面板');

}elseif(front::get('case')=='cache'){
	session::set('actname','生成操作');

}elseif(front::get('case')=='config' && $m4[1] == session::get('set')){
    session::set('actname',$n);
	$class1 = 'on';

}elseif(front::get('item') && $m6[1] == session::get('item')){
	session::set('actname',$n);
	$class1 = 'on';

}elseif(front::get('case')=='language' && $m2[1] == session::get('act')){
	session::set('actname',$n);
	$class1 = 'on';

}elseif(front::get('case')=='website' && $m2[1] == session::get('act')){
	session::set('actname',$n);
	$class1 = 'on';

}elseif(front::get('case')=='database' && $m2[1] == session::get('act')){
	session::set('actname',$n);
	$class1 = 'on';

}elseif(front::get('case')=='sms' && $m2[1] == session::get('act')){
	session::set('actname',$n);
	$class1 = 'on';

}else{
	$class1 = '';
}


/*if(front::get('tagfrom')){
	session::set('actname','标签列表');
	$class1 = '';
}*/

if($m3[1] == 'templatetag' && !($m2[1] == front::get('act') && $m5[1] == front::get('tagfrom'))){
	$class1 = '';	
}

if(front::get('type')=='subscription' || session::get('act')=='send' ){
	$class1 = '';
}

if(front::get('case')=='index'){
	$class1 = '';
}

if(front::get('case') == 'table' && front::get('act') == 'list' && front::get('table') == 'archive')
{
	if($m7[1] == '1' && front::get('needcheck') != '1'){
		$class1 = '';
	}
	if($m7[1] != '1' && front::get('needcheck') == '1'){
		$class1 = '';
	}
}

?>
<dd class="m{=$j++} {$class1}"><a href="{$m}" {if $n=='CNZZ站长统计'}target="_blank"{/if}><span class="d{=$k++}">{$n}</span></a></dd>
{/loop}

<?php $i++;?>
<?php $j++;?>
<?php $k++;?>
{/if}
</dl>

{/loop}

</div>

</div>


<div id="right">

<div id="position">
<div class="position">
<a href="{$base_url}/index.php?admin_dir={get('admin_dir')}&site=default" title="后台首页">首页</a>
<span><?php echo session::get('modname');?></span>
<span><?php echo session::get('actname');?></span>
<?php if(front::get('deletestate')) echo ' ><span>回收站</span>'; if(front::get('needcheck')) echo ' ><span>待审核内容</span>'; ?>
</div>
<div class="quick">
<!-- <a href="javascript:managemap();">网站地图</a> -->
<a href="{$base_url}/"  target="_blank">网站首页</a>
<a href="{url::create('index/index/mod/cache')}">生成静态</a>
<a href="index.php?case=table&act=add&table=archive&admin_dir={get('admin_dir')}">添加内容</a>
<a href="{url::create('config/remove')}" class="on">更新缓存</a>
</div>
</div>

<div class="right">

<div id="right_box">

<script type="text/javascript"><!--
function table(o,a,b,c,d){
 var t=document.getElementById(o).getElementsByTagName("tr");
 for(var i=0;i<t.length;i++){
  t[i].style.backgroundColor=(t[i].sectionRowIndex%2==0)?a:b;
  t[i].onclick=function(){
   if(this.x!="1"){
    this.x="1";
    this.style.backgroundColor=d;
   }else{
    this.x="0";
    this.style.backgroundColor=(this.sectionRowIndex%2==0)?a:b;
   }
  }
  t[i].onmouseover=function(){
   if(this.x!="1")this.style.backgroundColor=c;
  }
  t[i].onmouseout=function(){
   if(this.x!="1")this.style.backgroundColor=(this.sectionRowIndex%2==0)?a:b;
  }
 }
}
// --></script>




<?php
$this->render();
?>




<script type="text/javascript">
<!--
//table("表格名称","奇数行背景","偶数行背景","鼠标经过背景","点击后背景");
table("table1","#F5F5F5","#F9F9F9","#FFFFF0","#F5F5F5");

table("table2","#F5F5F5","#F9F9F9","#FFFFF0","#F5F5F5");

table("table3","#F5F5F5","#F9F9F9","#FFFFF0","#F5F5F5");

table("table4","#F5F5F5","#F9F9F9","#FFFFF0","#F5F5F5");

table("table5","#F5F5F5","#F9F9F9","#FFFFF0","#F5F5F5");

table("table6","#F5F5F5","#F9F9F9","#FFFFF0","#F5F5F5");

table("table7","#F5F5F5","#F9F9F9","#FFFFF0","#F5F5F5");

table("table8","#F5F5F5","#F9F9F9","#FFFFF0","#F5F5F5");

table("table9","#F5F5F5","#F9F9F9","#FFFFF0","#F5F5F5");
// -->
</script>

<div class="clear"></div>
</div>



</div>

<div class="right_bottom">

</div>
</div>




<div id="footer">



</div>



</div>

<div class="clear"></div>
</div>

<div class="blank30"></div>


<?php if(hasflash()) { ?>
<div id='message'><?php echo showflash(); ?>
<a href="#" onclick="javascript:turnoff('message')">&nbsp;(×)</a> 
</div><?php } ?>

<!--[if ie 6]>
	<script src="http://letskillie6.googlecode.com/svn/trunk/letskillie6.zh_CN.pack.js"></script>
<![endif]-->

</body>
</html>