<?php
	!defined('DIRCMS_MANAGE') && exit('Access Denied!');
?>
<!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">
<head>
<title>数据库管理</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<link rel="stylesheet" type="text/css" href="admin/template/css/style.css" />
<script type="text/javascript" src="images/js/jquery.min.js"></script>
<script type="text/javascript" src="admin/template/js/admin.js"></script>
</head>
<body>
<div id="wrap">
	<div class="tab">
		<ul>
			<li><a href="?file=db&action=export">数据备份</a></li>
			<li><a href="?file=db&action=import">数据还原</a></li>	
			<li><a href="?file=db&action=repair">数据修复</a></li>	
			<li><a href="javascript:void(0);" class="on">执行SQL</a></li>		
		</ul>
	</div>
	<div class="main">
	<fieldset>
		<legend>操作提示</legend>
		1：请谨慎执行此操作!； 2：多个SQL语句用' ; '隔开。
	</fieldset>
	<?php if(!DOSQL){echo '<font color="#FF0000">出于安全性考虑,管理员已禁止后台执行SQL!</font>';}else{?>
	<form action="" method="post" name="myform">
	<input type="hidden" name="do_submit" value="1" />
	<table cellspacing="0" class="sub">
		<tr>
			<td width="80" align="right">SQL语句：</td>
			<td>
			<textarea name="sql" cols="50" rows="5"></textarea>
			</td>
		</tr>
		<tr class="bg2"><td></td><td><input type="button" class="button" onclick="if(confirm('确定要执行此操作?'))this.form.submit();" value="执行SQL" /> <input type="button" class="button" onclick="window.location.href='<?php echo ADMIN_FILE;?>?file=db&action=export'" value="取消返回" /></td></tr>
	</table>
	</form>
	<?php }?>
	</div>
</div>
</body>
</html>