From 83a1681634804c47d5f7f675ff34d0cd3aa0d111 Mon Sep 17 00:00:00 2001 From: Bigsk Date: Thu, 1 Oct 2020 00:36:47 +0800 Subject: [PATCH] update api.php. --- api.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/api.php b/api.php index d36a2e5..7486bbd 100644 --- a/api.php +++ b/api.php @@ -187,13 +187,16 @@ if($_GET['mode'] == 'advanced'){//判断是否是高级模式 imagepng($canvas);//输出图片 imagedestroy($canvas);//关闭进程 }elseif($error == 10001){ + header("Content-type:application/json;charset=utf-8"); echo '{"error": "10001"}'; } } }else{ if($_GET['donor'] == null){ + header("Content-type:application/json;charset=utf-8"); echo '{"error": "10001"}'; }elseif($_GET['team'] == null){ + header("Content-type:application/json;charset=utf-8"); echo '{"error": "10001"}'; }else{ $canvas = imagecreatetruecolor(465, 92);//载入画布