'ThinkPHP.CN', //验证码加密密钥 'fontSize' => 22, // 验证码字体大小(px) 'imageH' => 50, // 验证码图片高度 'imageW' => 180, // 验证码图片宽度 'length' => 4, // 验证码位数 'fontttf' => '4.ttf', // 验证码字体,不设置随机获取 ); ob_clean(); $verify = new \Think\Verify($config); $verify->codeSet = '0123456789'; $verify->entry($id); } /** * 页码显示 * @param $count * @param int $row * author: xmy 280564871@qq.com */ public function showPage($count,$row=10){ if($count > $row){ $page = new \Think\Page($count, $row); $page->setConfig('theme','%FIRST% %UP_PAGE% %LINK_PAGE% %DOWN_PAGE% %END% %HEADER%'); $this->assign('_page', $page->show()); } } }