摘要: function timediff($begin_time,$end_time) { if($begin_time < $end_time){ $starttime = $begin_time; $endtime = $end_time; } else{ $starttime = $end_time 阅读全文
posted @ 2018-05-18 10:18 lsbaiwyl 阅读(261) 评论(0) 推荐(0) 编辑
摘要: function curlRequest($url, $data=array(), $method = 'GET'){ $method = strtoupper($method); $ch = curl_init(); curl_setopt($ch, CURLOPT_FAILONERROR, 1) 阅读全文
posted @ 2018-05-18 09:56 lsbaiwyl 阅读(217) 评论(0) 推荐(0) 编辑
摘要: /** * 取汉字的第一个字的首字母 * @param type $str * @return string|null */ function getFirstCharter($str){ if(empty($str)){return '';} $str=preg_replace('/·/', "" 阅读全文
posted @ 2018-05-18 09:47 lsbaiwyl 阅读(383) 评论(0) 推荐(0) 编辑