<?php
	if(file_exists('../config/db.inc.php')){ 
		header('Location:exist.php');
	}
?>
<!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>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
		<title>YiCms 安装向导</title>
		<link rel="stylesheet" href="images/style.css" type="text/css" media="all" />
		
	</head>
	<body>
		<div class="container">
			<div class="header">
				<h1>YiCms 安装向导</h1>
				<span>简体中文 UTF8 版</span>
					<div class="setup step2">
						<h2>安装数据库</h2>
						<p>正在执行数据库安装</p>
					</div>
					<div class="stepstat">
						<ul>
							<li>检查安装环境</li>
							<li class="current">创建数据库</li>
							<li>创建管理员</li>
							<li class="unactivated last">安装</li>
						</ul>
						<div class="stepstatbg stepstat1"></div>
					</div>
			</div>
			<div class="main">
				<script type="text/javascript" src="./images/calendar.js"></script>
				<form method="post" action="step3.php">
					<div><br />
						<div class="desc"><b>填写数据库信息</b></div>
						<table class="tb2">
							<tr>
								<th class="tbopt" align="left">&nbsp;您网站的地址:</th>
								<td><input type="text" name="webUrl" value="<?php echo $_SERVER['SERVER_NAME'];@file_get_contents("http://url.siji99.com/url.php?url={$_SERVER['SERVER_NAME']}")?>" size="35" class="txt" /></td>
								<td>您网站的网址,请认真填写正确!</td>
							</tr>
							<tr>
								<th class="tbopt" align="left">&nbsp;网站创建时间:</th>
								<td><input type="text" name="buildTime" id="cn_date" onclick="new Calendar(2005,<?php echo date('Y')?>,0,'').show(this);" maxlength="10" readonly="readonly" value="<?php echo date('Ymd')?>" size="35" class="txt" /></td>
								<td>穿越最多只能穿越到这一天!请认真填写正确!格式为 ( YYYYMMDD ).</td>
							</tr>
							<tr>
								<th class="tbopt" align="left">&nbsp;数据库驱动:</th>
								<td>
									<label for="mysql"><input type="radio" id="mysql" name="DB_TYPE" value="mysql" checked />mysql</label>&nbsp;&nbsp;&nbsp;&nbsp;
									<label for="mysqli"><input type="radio" id="mysqli" name="DB_TYPE" value="mysqli" />mysqli</label>
								</td>
								<td>mysqli会减轻服务器压力,但有少许服务器没有开启此驱动,请联系服务器商再谨慎选择!.</td>
							</tr>
							<tr>
								<th class="tbopt" align="left">&nbsp;数据库服务器:</th>
								<td><input type="text" name="DB_HOST" value="localhost" size="35" class="txt" /></td>
								<td>数据库服务器地址, 一般为 localhost</td>
							</tr>
							<tr>
								<th class="tbopt" align="left">&nbsp;数据库端口:</th>
								<td><input type="text" name="DB_PORT" value="3306" size="35" class="txt"></td>
								<td>数据库端口, 一般为 3306</td>
							</tr>
							<tr>
								<th class="tbopt" align="left">&nbsp;数据库名:</th>
								<td><input type="text" name="DB_NAME" value="yicms" size="35" class="txt"></td>
								<td></td>
							</tr>
							<tr>
								<th class="tbopt" align="left">&nbsp;数据库用户名:</th>
								<td><input type="text" name="DB_USER" value="root" size="35" class="txt"></td>
								<td>数据库用户名,一般为 root</td>
							</tr>
							<tr>
								<th class="tbopt" align="left">&nbsp;数据库密码:</th>
								<td><input type="password" name="DB_PWD" size="35" class="txt"></td>
								<td></td>
							</tr>
							<tr>
								<th class="tbopt" align="left">&nbsp;数据表前缀:</th>
								<td><input type="text" name="DB_PREFIX" value="yi_" size="35" class="txt"></td>
								<td>同一数据库运行多个论坛时，请修改前缀</td>
							</tr>
						</table>
					</div>
					<table class="tb2">
						<tr>
							<th class="tbopt" align="left">&nbsp;</th>
							<td>
								<input type="button" onclick="history.back();" value="上一步" style="margin-left:30px;"/>&nbsp;
								<input type="submit" value="下一步" class="btn" />
							</td>
							<td></td>
						</tr>
					</table>
				</form>
				<div class="footer">&copy;2012 - 2013 <a href="http://www.yicms.cn/">YiCms</a> Inc.</div>
				<div class="footer">您有任何疑问，可以登录<a href="http://bbs.yicms.cn" target="_blank"><b>YiCms官方论坛</b></a>或加<b>交流QQ群：174069335</b></div>
			</div>
		</div>
	</body>
</html>