-
GuzzleHttp简单使用
``` $client = new \GuzzleHttp\Client(); $url=’http://restapi.amap.com/v3/geocode/regeo’;
-
宝塔webhook+coding配置自动部署
- 安装webhook
-
PHP判断上午还是下午的实现方法
date_default_timezone_set('PRC'); //设置中国时区 echo str_replace(array('AM','PM'),array('上午','下午'),date("Y-m-d A H:i:s"));
-
Fastadmin基础知识(三)
- simditor编辑器图片超出样式
.simditor-body img{ max-width: 98%; height: auto; }
- simditor编辑器图片超出样式
-
ThinkPHP连表求和
$list = $this ->alias('us') ->field("us.id,ifnull(up.sales,0) as sales,us.name,us.mobile,us.lat,us.lng,us.distance,us.address_map, (6371 * acos (cos ( radians($lat) ) * cos( radians( lat ) ) * cos( radians( lng ) -...
商家列表隔2条插入广告
$adsList = ['ad_1','ad_2','ad_3','ad_4','ad_5','ad_6','ad_7','ad_8','ad_9','ad_10']; $shopList = ['shop_1','shop_2','shop_3','shop_4','shop_5','shop_6','shop_7','shop_8','shop_9','shop_10']; $newShopList=[]; if(!empty($shopList)){ $newShopList=$shopList; $y=0; for($i=1;$i<=count($shopList);$i++) { if($i%2==0){ if(!empty($adsList[$y])){ $append=[ $adsList[$y] ]; array_splice($newShopList, $i+$y, 0, $append); } $y++; } } }...
thinkphp5使用model查询数据时exists作为条件的用法
在thinkphp框架中如果使用model查询数据,有时候需要用到exists作为条件,具体代码应该怎么写呢?下面我们就来看看。
mysql bin 恢复_MySQL数据库恢复(使用mysqlbinlog命令)
1:开启binlog日志记录修改mysql配置文件mysql.ini,在[mysqld]节点下添加
14/38