在当前控制器定义一个actions的方法public function actions(){ return array( // 'captcha'=>array( 'class'=>'CCaptchaAction', 'backColor'=>0xFFFFFF, ), // ...
分类:
其他好文 时间:
2014-08-05 13:49:19
阅读次数:
191
1.控制器中public function actions() { return [ 'captcha' => [ 'class' => 'yii\captcha\CaptchaAction', 'fixedVerifyCode' => YII_ENV_...
分类:
其他好文 时间:
2014-07-18 11:36:01
阅读次数:
257
$this->createAction('captcha')->getVerifyCode(); //获取当前验证码的值当前页面url echo Yii::app()->request->url;跳转前一个页面url $this->redirect(Yii::app()->request->urlR...
分类:
其他好文 时间:
2014-07-09 17:00:58
阅读次数:
155
ci 之验证码为了方便,把 system/system/helpers/captcha_helper.php复制放在 application/helpers/文件夹里面手册上面推荐用数据库,但个人认为用 $_SESSION方便些(session必须开启)打开 application/helpers/...
分类:
其他好文 时间:
2014-07-06 15:53:20
阅读次数:
191
@1.验证码 1 captcher.php 2 header('Content-type:image/png'); 3 session_start(); 4 $img = imagecreate(100, 30); 5 $captcha = array( 6 'a', 'b', 'c', '...
分类:
Web程序 时间:
2014-07-03 23:42:31
阅读次数:
461
转载自http://www.cnblogs.com/descusr/p/3225874.html
所有程序写完之后,验证码图片不显示,点击图片地址会提示如下错误,并且在linux下的纠正办法
用pil产生验证码出现:ImportError: The _imagingft C module is not installed
这个是由于PIL没有编译freetype导致的...