if (empty($code) || empty($secode)) {
return false;
}
// session 过期
if (time() - $secode['verify_time'] > $this->expire) {
Session::delete($key, '');
return false;
}
if ($this->authcode(strtoupper($code)) == $secode['verify_code']) {
$this->reset && Session::delete($key, '');
return true;
}
return false;
}
/**
* 输出验证码并把验证码的值保存的session中
最佳答案