当前位置:首页 > 搜索 "thinkphp6"

THINKPHP官方推荐第三方插件库

zhangsir2年前 (2023-06-12)129
thinkphp6自动化CURDiszsw/curd——https://github.com/iszsw/curd验证和权限控制PHP-Casbincasbin/casbin——https://github.com/php-casbin/php-casbin6.0Authorizati......

thinkphp6 如何安装扩展

zhangsir2年前 (2023-03-09)144
thinkphp6中安装扩展通常需要以下几个步骤:1.打开composer.json文件,将要安装的扩展添加到require或require-dev中,例如:{    "require": { &n......

thinkphp6 对于大数据的性能优化处理

zhangsir3年前 (2023-01-15)165
thinkphp6做api,前端用layui框架做分页界面。实现分页功能。查询总数$page = Db::query("SELECT COUNT(*) FROM think_user")[0]['COUNT(*).....

thinkphp6 大数据分页,计算分页总量,layui分页

zhangsir3年前 (2023-01-11)134
官方文档给的解决方法:$list = Db::name('user')->where('status',1)->paginateX(50);但这个方法能分页,不能给出总数来,所以总数需要自己算一下。$page = i...

thinkphp6 搜索功能实现

zhangsir3年前 (2023-01-09)151
thinkphp6搜索功能实现1创建模型(例如User模型)模型类函数的命名规范:searchFieldNameAttr,FieldName根据自己的需要随意命名。例如下面的searchNameAttr。<?phpnamespace app\model;use ......

thinkphp6内置上传类的基本使用

zhangsir3年前 (2023-01-06)134
<strong><mark>thinkphp6</mark></strong>内置上传类的基本使用
thinkphp6内置上传类上传文件//上传接口public function filef(){    //获取上传文件    $file = request()-......

thinkphp6使用swoole步骤实例

zhangsir3年前 (2023-01-04)123
thinkphp6的自定义指令功能php think make:command Tcp tcp三,修改Tcp.php文件(位于:app\command\Tcp)<?phpnamespace app\command;use th......

thinkphp6 把用Db类的条件查询转成原生的sql语句

zhangsir3年前 (2022-11-23)189
thinkphp6经常需要查看SQL原生语句,这里有两种方式获取:1、getLastSql(),获取方法前最后一条SQL原生语句$a1 = Movies::where('state',1)->limit(10)->select();$a2......

thinkphp6 创建自定义命令行指令

zhangsir3年前 (2022-11-04)220
第一步,创建一个自定义命令类文件,运行指令php think make:command Hello hello会生成一个app\command\Hello命令行指令类,我们修改内容如下<?phpnamespace app\command;......

thinkphp6框架安装及扩展安装

zhangsir3年前 (2022-08-21)333
1.安装开发版composercreate-projecttopthink/think=6.0.x-devtp2.安装模板扩展composerrequiretopthink/think-view3.安装验证码扩展composerrequiretopthink/think-captcha......