- 博客(14)
- 收藏
- 关注
原创 vue h5stream 使 rtsp 视频流在浏览器中播放
一、在官网中下载文件 https://linkingvision.cn/product/h5stream下载 release 最新版本二、解压后 第一次运行 文件, 只在刚安装时运行一次。三、如需修改端口请找到 conf/h5ss.conf 这个文件。四、运行 h5ss.bat 文件启动服务。五、访问网址 : http://localhost:8081 能访问到登录页安装成功。 admin 12345六、引入文件https://github.com/linkingvision/
2021-09-02 00:33:52
1774
原创 laravel 获取 模块 控制器 方法名
/** * 获取 模块 控制器 方法名 */ final protected function getTemplatePath() { list($class, $method) = explode('@', $this->request->route()->getActionName()); # 模块名 ...
2019-03-26 16:57:46
6467
原创 laravel artisan 自定义控制器模板
laravel artisan 自定义控制器模板1 生成命令2 更改命令文件3 执行命令:1 生成命令php artisan make:command AppMakeCommand该命令会在 app/Console/Commands 目录下创建一个新的命令类在 Commands 目录下 差创建 stubs 目录 放入模板文件 controller.plain.stubcontrolle...
2019-03-22 11:31:17
1161
原创 php 自定义打印函数
function pr(){ foreach (func_get_args() as $k => $v) { $templat = PHP_SAPI !== 'cil' ? '<pre>%s</pre>' : "\n%s\n"; printf($templat, print_r($v, true)); }}
2018-12-21 01:54:29
570
原创 随机字符串
/**随机字符*/protected function salt($len) { // 组成数组 $arr = array_merge(range(0, 9), range('a', 'z'), range('A', 'Z')); // 数组随机排序 shuffle($arr); // 取得随机个数值...
2018-05-09 19:00:20
128
原创 docker 国内镜像加速
通过修改daemon配置文件/etc/docker/daemon.json来使用加速器 centos:sudo mkdir -p /etc/docker sudo tee /etc/docker/daemon.json <<-‘EOF’ { “registry-mirrors”: [“加速地址”] } EOF sudo systemctl daemon-reload...
2018-05-02 17:07:13
494
原创 内容图片地址加上域名
$content = preg_replace_callback('//', function ($r) { $str = 'http://'.$_SERVER['HTTP_HOST'].$r[1]; return str_replace($r[1], $str, $r[0]); },
2018-02-01 09:30:55
2132
转载 liunx 端口设置
安装iptable iptable-serviceCentOS7安装iptables防火墙 CentOS7默认的防火墙不是iptables,而是firewalle. - 先检查是否安装了iptables service iptables status - 安装iptables yum install -y iptables - 升级iptables yum update ipta
2018-01-15 17:49:19
279
原创 php 修改文件
php 修改文件/** * 修改文件 * @author GRACE * @param $file 文件路径 * @param $arr 修改值数组 * @param $len 开始索引位置 * @param $end 结束索引位置 或 匹配 索引值 * @param bool $loke 文件为空时,是否添加 <?php 头
2018-01-02 18:12:30
1267
转载 php微信app支付
场景介绍 适用于商户在移动端APP中集成微信支付功能。 商户APP调用微信提供的SDK调用微信支付模块,商户APP会跳转到微信中完成支付,支付完后跳回到商户APP内,最后展示支付结果。 目前微信支付支持手机系统有:IOS(苹果)、Android(安卓)和WP(Windows Phone)。 文档参考 https://pay.weixin.qq.com/wiki/doc/api/app/ap
2017-12-25 19:56:47
872
转载 liunx 常用压缩命令
Liunx 压缩解压文件或目录常用命令.gz 格式gzip fileName # 压缩文件gzip -d fileName.gz # 解压缩文件gunzip fileName.gz # 解压缩文件注意:只能压缩文件而不能压缩目录,且不保留原文件.tar.gz 格式tar -czvf folderName.tar.gz folderName # 压缩目录或文件
2017-12-25 11:22:38
322
转载 质合数判断
$primeNumbersSumNumbers = $v == 1 ? '' : '质'; // 默认为质数for ($j = 2; $j*$j <= $v; $j++) { if ($v%$j == 0) { $primeNumbersSumNumbers = '合'; }}
2017-12-14 17:02:24
915
转载 PHP + curl 实现 http 或 https 抓取数据:
PHP + curl 实现 http 或 https 抓取数据:/*** 抓取数据 https 或 http 形式* @param $url 链接 * @param $data 参数* @return mixed 返回数据*/private function curlS($url, $data){ $UserAgent = 'Mozilla/4.0 (compat
2017-12-13 18:48:07
2986
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人