<?php
define('MICE_INSTSLL', 1);
include_once 'startup.php';
include_once 'admin.functions.php';

define('MICE_URL', substr("http://".$_SERVER['HTTP_HOST'].$_SERVER["SCRIPT_NAME"],0,strrpos("http://".$_SERVER['HTTP_HOST'].$_SERVER["SCRIPT_NAME"],'/')+1));

if(!MICE_SETUP and $_POST['username']==''){
	die('<!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></title></head><body>网站已安装成功！</body></html>');
}
class getTPLFileName {
	public $TPLFileName;
	function getTPLFileName($classname) {
		$classname=str_replace('Action',MICE_EXT,$classname);
		$this->TPLFileName="install/".$classname;
	}
}

try{
	$router=new miceRouter();
	$router->set_path(MICE_DIR.'install');
	$router->dispatch();
}catch (Exception $e){
	echo $e;
}
?>