Author: Tianfeng.Han
Esempio n. 1
0
 function vcode()
 {
     $this->session->start();
     $this->http->header('Content-Type', 'image/jpeg');
     $verifyCode = Swoole\Image::verifycode_chinese('/usr/share/fonts/truetype/wqy/wqy-microhei.ttc');
     //        debug($verifyCode);
     //        $verifyCode = Swoole\Image::verifycode_gd();
     //        $verifyCode = Swoole\Image::verifycode_imagick();
     $_SESSION['vcode'] = $verifyCode['code'];
     return $verifyCode['image'];
 }
Esempio n. 2
0
 function vcode()
 {
     $this->session->start();
     $this->http->header('Content-Type', 'image/jpeg');
     Swoole\Image::verifycode_gd();
 }
Esempio n. 3
0
 function verify()
 {
     session();
     $this->swoole->http->header('Content-Type', 'image/png');
     Swoole\Image::verifycode_gd();
 }