<html><hand>
<meta HTTP-EQUIV="Content-Type" CONTENT="text/html;charset=<?php echo CHARSET;?>">
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7">
<meta HTTP-EQUIV="Content-Language" CONTENT="<?php echo CHARSET;?>">
<script language='JavaScript' src='admin/img/admin.js'></script>
<link href="admin/img/style.css" rel="stylesheet" type="text/css">
<?php 
if(!defined('IN_ADMIN')) exit('Access Denied');
switch ($action){
	case 'add':
?>
<table width='100%' cellpadding=3 cellspacing=1 class=td1>
<form name='myform' method='post' Action='<?=SCRIPT_NAME;?>?file=page&action=add'>
<tr class=td4><td colspan=2><strong>添加单页面</strong></td></tr>
<tr class=td2><td width='10%'><strong>标题</strong></td>
<td width='90%'><input name=info[title] maxlength=20 value="" style='height:18px;width:150px'></td></tr>
<tr class=td2><td><strong>内容</strong></td>
<td><?php $editor->Create();?></td></tr>
<tr class=td2><td></td>
<td><input type=submit value=' 提 交 ' name='dosubmit'></td></tr>
</form>
</table>
<?php 	
	break;
	case 'list':
	?>
<table width='100%' cellpadding=3 cellspacing=1 class=td1>
<tr class=td4><td colspan=3><strong>单网页管理</strong></td></tr>
<tr align='center' class=td3>
<td width='30%'>单页标题</td>
<td width='50%'>单页连接</td>
<td width='20%'>操作</td></tr>
<?php 
if(is_array($p) && !empty($p)){
	foreach($p as $pages){ 
?>
<tr align=center class=td2 onMouseMove="this.className='td3'" onMouseOut="this.className='td2'">
<td><?=$pages['title']?></td>
<td><span class=Font2>?file=page&id=<?=$pages['id']?></span></td>
<td><span class=Font5><a href="?file=page&action=edit&id=<?=$pages['id']?>">修改</a> | <a href="?file=page&action=del&id=<?=$pages['id']?>">删除</a></span></td>
</tr>
<?php }}?>
</table>
<table width='100%' border=0 cellspacing=0 cellpadding=5 style='border-top:1px #C4D8ED solid'>
<tr><td align=center class=td2><?=$dispage;?>
</td>
</tr>
</table>
<?php 	
	break;
	case 'edit':
	?>
	<table width='100%' cellpadding=3 cellspacing=1 class=td1>
<form name='myform' method='post' Action='<?=SCRIPT_NAME;?>?file=page&action=edit'>
<tr class=td4><td colspan=2><strong>修改单页面</strong></td></tr>
<tr class=td2><td width='10%'><strong>标题</strong></td>
<input name=id type=hidden value='<?=$p['id']?>'>
<td width='90%'><input name=info[title] maxlength=20 value="<?=$p['title']?>" style='height:18px;width:150px'></td></tr>
<tr class=td2><td><strong>内容</strong></td>
<td><?php $editor->Create();?></td></tr>
<tr class=td2><td></td>
<td><input type=submit value=' 提 交 ' name='dosubmit'></td></tr>
</form>
</table>
	<?php 
	break;
}
?>