添加跨域
添加服务后台添加
This commit is contained in:
@@ -26,6 +26,10 @@ use think\facade\Config;
|
||||
use think\facade\Debug;
|
||||
use think\Response;
|
||||
|
||||
header("Access-Control-Allow-Origin: *");
|
||||
header("Access-Control-Allow-Methods: GET, POST, PUT, DELETE, OPTIONS");
|
||||
header("Access-Control-Allow-Headers: Content-Type, Authorization");
|
||||
|
||||
class ApiBase extends Controller
|
||||
{
|
||||
public $user_info = [];
|
||||
|
||||
Reference in New Issue
Block a user