随笔分类 - PHP
摘要:if (!function_exists('msec_time')) { function msec_time() { [$msec, $sec] = explode(' ', microtime()); $msectime = (float)sprintf('%.0f', (floatval($m
阅读全文
摘要:代码 //行为限频 if (!function_exists('doSomethingLimit')) { function doSomethingLimit($key, $second, Closure $callback) { $reids = get_redis(); if ($reids->
阅读全文
摘要:报错信息 laravel which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by 关闭严格模式: 修改 app/d
阅读全文
摘要:Ios苹果支付流程: 客户端先从苹果获取内购Id。 客户端将内购id,金额、用户id等传给服务端获取一个自己服务端生成的订单号。 客户端向苹果发起支付。 支付成功后,客户端从本地拿支付凭证、将支付凭证和订单号、用户id等参数传给服务端;服务端拿支付凭证向苹果发起验证订单是否有效,然后将结果反馈给客户
阅读全文
摘要:框架报500 1.chmod 777 -R storage 将日志目录权限设置下。 2.修改fastcgi,将代码目录包含进去。 fastcgi_param PHP_ADMIN_VALUE "open_basedir=$document_root/:/tmp/:/proc/:/home/www/";
阅读全文
摘要:在Laravel中使用分组求和,如果直接使用Laravel各数据库操作方法,应该会得出来如下代码式: DB::table('table_a') ->where('a','=',1) ->groupBy('b') ->select("sum(c) as d") ->get(); 但是,这么做会报错,因
阅读全文