自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(21)
  • 收藏
  • 关注

原创 PHPExcel 操作整理

【代码】PHPExcel 操作整理。

2023-07-06 19:48:12 262

原创 PHP处理 EXCEL 日期格式

PHP 处理 Excel 日期格式

2021-12-04 11:31:21 547

原创 TP5 Cache

缓存设置:Cache::set('name',$value,3600);Cache::set('name',$value,new DateTime('2017-10-1 12:00'));获取缓存:Cache::get('name');Cache::get('name','');删除缓存:Cache::rm('name'); 获取缓存并删除:Cache::pull('name'); 清空缓存:Cache::clear(); 不存在则写入缓存数据后返回:Cache::rem

2021-02-01 13:53:09 495

原创 FastAdmin 常用操作

CURD生成 fa_test 表的 CURDphp think curd -t test生成 fa_test 表的 CURD 且一键生成菜单php think crud -t test -u 1删除 fa_test 表生成的 CURDphp think crud -t test -d 1生成 fa_test 表生成的 CURD 且关联模型 category,外链为 category_id,关联表主键为idphp think crud -t test -r category -

2021-01-14 11:49:41 511

原创 宝塔lnmp环境 添加站点后提示 No input file specified.

宝塔lnmp环境 添加站点后提示 No input file specified.解决方法: 修改 /www/server/nginx/conf/fastcgi.conf 文件添加代码: fastcgi_param PHP_ADMIN_VALUE “open_basedir=/www/wwwroot/:/tmp/:/var/tmp:/proc/”;

2020-10-13 10:13:02 264

原创 Mysql 相关操作

新建用户并添加远程访问权限:create user zhxd identified by 'zhxd';grant all privileges on oa_cloud.* to zhxd@'118.81.55.22' identified by 'zhxd';flush privileges;删除用户drop user zhxd@'118.81.55.22';查看命令:show grants for 'zhxd';授权类型:all privileges:所有权限。select:读取

2020-10-10 15:53:57 109

原创 在Ngix或Tengine服务器上安装证书

阿里云免费证书在Ngix或Tengine服务器上安装证书说明本文档以 Centos 8、Nginx 1.14.1 为例进行说明,由于版本不同,您在操作过程中的命令可能不同本文档证书名称以 domain name 为例,例如证书文件名称为 domain name.pem , 证书密钥文件名称为 domain name.key下载的Nginx证书压缩文件解压后包含:.pem : 证书文件,PEM 文件的扩展名为CRT格式.key: 证书密钥文件。申请证书时如果未选择自动创建CRS,则下载的证书

2020-09-14 11:22:15 130

原创 TP5 相关操作

TP 记录数组日志:方法一: $arr = print_r([1,2,4], true); Log::write($arr);方法二: $arr = var_export([1,2,3], true); Log::write($arr);

2020-09-08 11:33:28 109

原创 Mysql 导入报错 Invalid default value for update_time

Mysql 导入时,timestamp 格式默认为Null时导入报错原因:MySQL 5.6版本引入 explicit_defaults_for_timestamp ,来控制对timestamp NULL值的处理修改:将 explicit_defaults_for_timestamp 值修改为 ON

2020-06-05 18:10:05 469

原创 VScode 相关操作

显示空格和制表符打开 文件->首选项->设置, 在输入框中 搜索 renderControlCharaters, 选中勾选框,即可显示tab在搜索框中输入 renderWhiteSpace, 选择 all, 即可显示空格

2020-06-02 20:07:18 150

原创 TP5 验证器

验证器定义一个 \app\index\validate\User 验证器类用于 User 的验证: namespace app\index\validate uses think\Validate; class User extends Validate { protected $rule = [ 'name' => 'require|max:25', 'email' => 'email', ]; protected $message = [ 'name.r

2020-05-14 16:45:43 300

原创 Git 常用操作

Git 相关操作查看所有分支git branch -a查看当前所在分支git branch删除本地分支git branch -d 分支名称删除远程分支git push origin --delete 分支名称

2020-05-13 18:00:36 120

原创 git 出现 fatal: refusing to merge unrelated histories 错误

git pull 失败 ,提示:fatal: refusing to merge unrelated histories其实这个问题是因为 两个 根本不相干的 git 库, 一个是本地库, 一个是远端库, 然后本地要去推送到远端, 远端觉得这个本地库跟自己不相干, 所以告知无法合并具体的方法, 一个种方法: 是 从远端库拉下来代码 , 本地要加入的代码放到远端库下载到本地的库, 然后提交上...

2019-08-05 09:44:41 145

转载 windows 下git出现警告:warning: LF will be replaced by CRLF in test1.txt. The file will have its original

1.问题git在执行git add命令时出现以下警告:warning: LF will be replaced by CRLF in test1.txt. The file will have its original line endings in working directory2.原因因为Git的换行符检查功能。LF是linux下的换行符,而CRLF是enter + 换行。...

2019-08-05 09:35:31 2964

原创 laravel

安装composer create-project --prefer-dist laravel/laravel oaphp artisan key:generatelocation / { try_files $uir $uri/ $uri/index.php?$query_string;}

2019-08-04 10:49:30 97

转载 laravel配置路由出现404解决办法

问题分析一般出现这种情况的都是apache/nginx配置出现问题nginx解决办法在location里面加上 try_files $uri $uri/ /index.php?$query_string;如果配置文件中存在 try_files $uri $uri/ =404;需要将它注释掉或者删掉,否则会报错...

2019-07-30 12:51:13 1695

转载 php artisan migrate 报错: SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was to

执行php artisan migrate 报错 :Illuminate\Database\QueryException : SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; max key length is 1000 bytes (SQL: alter table user...

2019-07-30 12:38:24 605

转载 Composer install 报错:laravel/horizon v1.4.3 requires ext-pcntl * -> the requested PHP extension pcntl

错误提示:laravel/horizon v1.4.3 requires ext-pcntl * -> the requested PHP extension pcntl is missing from your system解决办法:在 composer.json 中增加“config”: {“preferred-install”: “dist”,“sort-packages”:...

2019-07-30 12:29:28 2713 2

原创 Ubuntu 16.04 英文版 安装 wine

sudo apt-get install libfreetype6-dev gobject* libxrender-dev libfontconfig-dev pthread* libpthread-stubs0-dev xext* libsm-devwget http://prdownloads.sourceforge.net/wine/wine-1.5.0.tar.bz2tar -xjv...

2018-08-28 08:57:21 372

转载 Ubuntu (错误): to lock the administration directory (/var/lib/dpkg/) is another process using i

Ubuntu 16.04 上的文件锁定错误错误如下:E: Could not get lock /var/lib/dpkg/lock - open (11: Resource temporarily unavailable)E: Unable to lock the administration directory (/var/lib/dpkg), is another proces...

2018-08-28 08:20:37 168

转载 英文版Ubuntu16.04安装fcitx-googlepinyin

英文版Ubuntu16.04安装fcitx-googlepinyin1、安装汉语语言包 sudo apt-get install language-pack-zh-hans 执行该命令后,系统就会自动安装所需要的汉语语言包2、安装谷歌拼音输入法 sudo apt-get install fcitx-googlepinyin 执行该命令后,系统就会自动...

2018-08-27 18:51:50 1251

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除