-
MySQL常用实例
-- 更新指定订单的发货状态和发货时间 -- update bz_order set `status`=2,send_time=unix_timestamp(now()) where id in('1','5') -- 查询规格名含有空格的数据 -- select * from bz_specs where `name`!=TRIM(`name`) -- 查询规格在另一张表中不存在的 -- select old.* from bz_specs_old...
常用时间戳转换
时间戳转换
/** * 当前日期的上一周的开始时间,结束时间和上一个月的开始时间和结束时间及时间戳 * @param string $date * @return array|string */ function week_of_month($date = ''){ date_default_timezone_set('Asia/Shanghai'); $date = empty($date) ? date('Y-m-d') : $date;//当前日期 $now_time=strtotime($date);//当前时间戳...
H5 GPS定位
H5 GPS定位
<script> if(getCookie('latitude')==null || getCookie('latitude')==undefined){ if (navigator.geolocation){ navigator.geolocation.getCurrentPosition(showPosition,showError,{ // 指示浏览器获取高精度的位置,默认为false enableHighAcuracy : true, // 指定获取地理位置的超时时间,默认不限时,单位为毫秒 timeout : 5000, // 最长有效期,在重复获取地理位置时,此参数指定多久再次获取位置。 maximumAge : 2000 });...
ThinkPHP5.0版本使用EXP
TP5.0版本EXP使用
5.0.17版本升级5.0.18版本时,EXP的写法变了,具体查看手册的升级指导
按照新的EXP表达式的写法
使用FIND_IN_SET:
原文链接:https://blog.csdn.net/zk9461/article/details/102521579
利用浏览器截取网页保存为图片
利用浏览器截取网页保存为图片(谷歌内核浏览器都可以)
1、点击f12
买羽绒服时,看懂吊牌的“秘密”,五个参数很重要
选羽绒服一定要看这五个参数,分别是填充物、充绒量、含绒量、蓬松度和清洁度,前四个指标确定的这个衣服的保暖程度,最后一个清洁度,可是跟健康息息相关。
获取汉字首字母功能
获取汉字首字母功能
if(!function_exists('getFirstCharter')) { /** * @param $str * @return string|null */ function getFirstCharter($str) { if (empty($str)) { return ''; } $fchar = ord($str[0]); if ($fchar...
ThinkPHP5 where 子查询
子查询
``` 1) ->where([‘user_id’=>15,’by_object’=>19])
24/38