/** * [code 验证码] * @return [type] [description] */ public function code() { $code = new verificationCode(80, 32, 4, false); $codeNum = $code->getCheckCode(); myRedis::set('code', $codeNum, 120, 's'); $codeImg = $code->showImage(); }
/** * [init 载入配置文件 实例化对象] * @return [type] [description] */ public static function init() { self::$redis = new Client(require BASE_PATH . self::CONFIG_FILE); }