加载中
mysql 主主复制

1. 环境:Red Hat 4.1.2-52,MySQL5.5.20 2. 两台机器: master1:192.168.76.7 master2:192.168.76.10 3. 单独编译安装MySQL,并测试连接成功。 4. 两台机器上都建立用户,并赋予复制权限: ...

2013/03/20 15:16
110
Nginx下载ipa或apk文件IE中变成zip

目前许多提供下载apk和ipa的地方,用IE浏览器下载完后文件自动变成了zip后缀,导致无法使用,只要在nginx的conf/mime.typs内加上 application/vnd.android.package-archive apk; application...

2012/10/23 17:55
1K
tree

递归生成树数组 /* $type=1 一维数组, $type=2 多维数组 */ function children($parent_id, $maxdepth = 0, $type = 1, $depth = 1, $all = array()){   if($maxdepth > 0 && $depth > $max...

2012/08/18 11:25
85
HTTP status codes AND mime types

/** * Holds HTTP response statuses * * @var array */   protected $_statusCodes = array(     100 => 'Continue',     101 => 'Switching Protocols',     200 => 'OK',     201 => 'Created...

2012/05/11 17:54
69
php http 断点续传

下载 download.php <?php $file = './Penguins.jpg'; $file_display_name = basename($file); $fsize = @filesize($file); if (!empty($fsize)) {         $start = null ;   $end = $fsize - 1;...

2012/05/09 10:46
829
php fsockopen 异步 post

yibu.php <?php $data["channel"]=1; $data["mobile"]=2; $data["gateway"]=3; $data["isp"]=4; $data["linkid"]=5; $data["msg"]=6; $post = http_build_query($data); $len = strlen($pos...

2012/05/09 10:21
2.3K
img lazy load php 正则替换

今天看到有人提问,觉得自己会用到,写了一个 html内容中的 <img src="images/1.jpg" imgtype="upload" /> <img src="images/2.jpg" imgtype="upload" /> 替换成 <img src="load.jpg" imgtyp...

2012/04/16 16:26
314
linux mysql 安装

wget http://mysql.cdpa.nsysu.edu.tw/Downloads/MySQL-5.5/mysql-5.5.20-linux2.6-x86_64.tar.gz 传到内网服务器 scp mysql-5.5.20-linux2.6-x86_64.tar.gz root@10.0.20.11:/root ssh 10.0...

2012/04/14 15:16
201
cakephp 使用 mongodb

记录一下地址 https://github.com/ichikaway/cakephp-mongodb 使用 mongodb group $ds = $this->getDataSource(); $key = array('file_type'=>1); $options = array('user_id'=>(int)$user_i...

2012/04/09 10:21
239

没有更多内容

加载失败,请刷新页面

没有更多内容

返回顶部
顶部