<?php
|
include_once '/Common/CommFunc.php';
|
include_once '/Common/Logging.php';
|
include_once "/db/DBOper.php";
|
|
header("Content-type: text/html; charset=utf-8");
|
|
\Logging\CreateLogging("centerapi.checkuser.php");
|
\Logging\LogInfo("_GET:" . print_r($_GET, true));
|
$tokenkey = $_GET["tokenkey"];
|
$channel = $_GET["channel"];
|
$guid = $_GET["guid"];
|
|
if (!$tokenkey || !$channel || !$guid) {
|
echo "ParamError";
|
exit;
|
}
|
|
if (!\DBOper\FindOne("UserToken", array("Channel" => $channel, "UserGuid" => $guid), $ret, null, true)) {
|
echo "DBError";
|
exit;
|
}
|
|
if (isset($ret) && $ret["Tokenkey"] == $tokenkey) {
|
echo "OK";
|
exit;
|
}
|
echo "NotFound";
|