安装callback优化

This commit is contained in:
hdm 2022-07-27 17:18:58 +08:00
parent a15ae16215
commit 94fc4c9b85

View File

@ -27,26 +27,6 @@ class Login
return View();
}
//系统安装提交
function install_ajax()
{
$url = $_SERVER["HTTP_REFERER"]; //获取完整的来路URL
$str = str_replace("http://","",$url); //去掉http://
$str = str_replace("https://","",$str); //去掉https://
$strdomain = explode("/",$str); // 以“/”分开成数组
$domain = $strdomain[0]; //取第一个“/”以前的字符
$name = '系统';
if (!empty($_GET['name'])) {
$name = $_GET['name'];
}
add_user_log('install', $name,0,['domain'=>$domain]);
if (!empty($_GET['callback'])) {
return $_GET['callback'] . '("install ok!")'; // jsonp
}
else{
return to_assign(1, 'install ok!');
}
}
//提交登录
public function login_submit()
{