shell脚本编程学习笔记(三)权限分配
文件或目录(普通文件) ------chmod scl 用户对某个程序或某个应用脚本-------sudo chmod 不能实现权限细化问题 1.数字权限分配 chmod 755 file r 4 w 2 x 1 2.字母权限分配 chmod u+x file chmod o-w file chmod g+w file chmod g+w,g+x file
文件或目录(普通文件) ------chmod scl 用户对某个程序或某个应用脚本-------sudo chmod 不能实现权限细化问题 1.数字权限分配 chmod 755 file r 4 w 2 x 1 2.字母权限分配 chmod u+x file chmod o-w file chmod g+w file chmod g+w,g+x file
查看文章权限 ls -l file ll Linux权限 r 可读 w 可写 x 可执行 Linux用户 所有者(u) 所属组(g) 其他用户(o) 所有用户(all) drwxr-xr-x. 3 root root 4096 Feb 7 12:38 mnt 第一个元素: d 文件夹 - 文件 r可读 w可写 x可执行 -无权限 root用户对mnt具有rw
更改IP地址 临时更改 ifconfig eth0 192.168.100.1 永久更改 vi /etc/sysconfig/network-scripts/ifcfg-eth0 tab键自动补全(tab) 例如:ifcon (tab) -------自动补全config 命令历史 查看 history 调用命令1 !+数字 调用命令2 !vi 最后一条以v
工作中使用的,觉得挺好用的,分享给大家 /** * 字符串截取,支持中文和其他编码 * @static * @access public * @param string $str 需要转换的字符串 * @param string $start 开始位置 * @param string $length 截取长度 * @param string $charset
PDO实现数据库的增删改查 //链接数据库 $pdo = new PDO('mysql:host=localhost;dbname=test','root','root'); //增 $res = $pdo->exec("insert into user(name) values('测试1')"); if($res){ echo '添加成功数据ID为:'.$
需要在公众号设置网页授权域名,否则会报错 报错:当前页面url未注册 在商户平台-----产品中心--开发配置--公众号支付---添加支付授权目录 域名/example/
统一下单 必填参数 https://pay.weixin.qq.com/wiki/doc/api/native.php?chapter=9_1 下单成功后使用异步回调修改订单状态 扫描支付页面(修改) $input->SetNotify_url("http://www.wangmingchang.com/example/notify.php") 在logs中
下载官方demo https://pay.weixin.qq.com/wiki/doc/api/native.php?chapter=11_1 配置商户信息 lib/Wxpay.config.php 在index.php中修改域名 3.修改example/native.php中的域名
准备: 1.认证的服务号 https://mp.weixin.qq.com/ 2.企业营业执照以及对公账号 3.已备案的域名和服务器 过程: 1.开通微信支付 2.开通商户平台 https://pay.weixin.qq.com 支付: 公众号支付 app支付 扫码支付 https://pay.weixin.qq.com/guide/webbased_pay
在application/extra下的配置文件都会被tp5自动加载 新建setting.php return[ 'img_prefix'=>'http://wmc.com/images' ] 使用模型的获取器拼接图片路径 tp5中只有public是公开的 public/images/1,jpg config('配置文件.配置名称'); $a = confi