摘要:
echo strtotime(date('Y-m-d')); 获取明天凌晨的时间戳代码:echo strtotime(date('Y-m-d',strtotime('+1 day'))); 附上测试代码:echo strtotime('2012-11-2');echo strtotime('2012... 阅读全文
摘要:
phpredis是php的一个扩展,效率是相当高有链表排序功能,对创建内存级的模块业务关系很有用;以下是redis官方提供的命令使用技巧:下载地址如下:https://github.com/owlient/phpredis(支持redis 2.0.4)Redis::__construct构造函数$r... 阅读全文
摘要:
阅读全文
摘要:
selectDB("banggoCMS"); //$db = $m->banggoCMS;$col = $db->dbeleComment2014;/*新增*//* $opt = array( 'fsync' => 1 //默认为 false , false时当日志配置开启时和 j... 阅读全文
摘要:
function getNext( $str ){ $ret = array(0=>0); for( $j =1; $j $l2) return $rt; $i = $p; $j = 0; $next = getNext($sstr); whil... 阅读全文
摘要:
var once = (function(){ var res = {}, i = 0 ; return function(func){ if(typeof(func) != 'function'){ alert('参数类型不正确'); ... 阅读全文
摘要:
nginx是一个web服务器,因此nginx的access日志只有对访问页面的记录,不会有php 的 error log信息。nginx把对php的请求发给php-fpm fastcgi进程来处理,默认的php-fpm只会输出php-fpm的错误信息,在php-fpm的errors log里也看不到... 阅读全文
摘要:
/** _ooOoo_ o8888888o 88" . "88 (| -_- |) O\... 阅读全文
摘要:
$filename = 'D://WWW/1.jpg';$p = 5;// Get new sizeslist($width, $height) = getimagesize($filename);$newwidth = $width;$newheight = floor($height / $p)... 阅读全文
摘要:
$ch = curl_init(); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POSTFIELDS, $data); curl_setopt(... 阅读全文