diff --git a/public/index.php b/public/index.php index 22dc158..675f1fc 100644 --- a/public/index.php +++ b/public/index.php @@ -15,6 +15,12 @@ namespace think; // 加载基础文件 require __DIR__ . '/../thinkphp/base.php'; + +if(!file_exists("install/lock")){ + $url=$_SERVER['HTTP_HOST'].trim($_SERVER['SCRIPT_NAME'],'index.php').'install/index.php'; + header("Location:http://$url"); + exit(); +} // 支持事先使用静态方法设置Request对象和Config对象 // 执行应用并响应