0

PHP-PACK-UNPACK用法

Posted in PHP at 四月 15th, 2010 / No Comments »

在看下面一个例子前先提及一组函数pack,unpack。 任何一款拥有socket操作能力的语言都有一个专门用于组包的函数,php也不例外当然这组函数的用途不仅仅是组包。 下面简单的介绍一下: 应用一: 输入16进制或者2进制...

0

Memcache的使用和协议分析详解

Posted in PHP at 四月 13th, 2010 / No Comments »

Memcache的使用和协议分析详解 作者:heiyeluren 博客:http://blog.csdn.net/heiyeshuwu 时间:2006-11-12 关键字:PHP Memcache Linux 缓存 Memcache是danga.com的一个项目,最早是为 LiveJournal 服务的,目前...

0

YAHOO YUI工具库

Posted in JavaScript, PHP at 三月 15th, 2010 / No Comments »

1.1. YAHOO工具库提供的方法 l namespace 用于创建一个全局的命名空间,使用YUI时,首先会自动创建widget,util,example三个命名空间,使用时也可以自定义命名空间。类似于在程序中建了了一个static变量。 l lang ...

0

FCKeditor限制图片上传尺寸

Posted in PHP at 十二月 9th, 2009 / No Comments »

1.         修改/fckeditor/editor/filemanager/connectors/php/config.php 注意:50的单位是 Kb $Config['AllowedExtensions']['Image'] = array(‘bmp’,'gif’,'jpeg’,'jpg̵...

0

在php中设置时区

Posted in PHP at 十二月 7th, 2009 / No Comments »

date_default_timezone_set (“PRC”); php时区设置老差8个小时解决办法2009-11-26 10:07发现一个问题 date(“Y-m-d G:i T”,time()) 取出来的时间和本地时间老差8个小时,可 我的系统明明是中国 标准时(GMT+8)...

0

清除ThinkPHP缓存目录

Posted in PHP at 十月 22nd, 2009 / No Comments »

ThinkPHP/Common/functions.php// 清除缓存目录 function clearCache($type=0,$path=NULL) { if(is_null($path)) { switch($type) { case 0:// 模版缓存目录 $path = CACHE_PATH; break; case 1:// 数据缓存目录 ...

0

正则表达式30分钟入门教程

Posted in PHP at 九月 13th, 2009 / No Comments »

版本:v2.21 (2007-8-3) 作者:deerchao 来源:unibetter大学生社区 转载请注明来源 目录 本文目标 如何使用本教程 正则表达式到底是什么? 入门 测试正则表达式 元字符 字符转义 重复 字符类 反义 替换 分组 后向...

0

exec函数执行cd没有用

Posted in Linux, PHP at 五月 7th, 2009 / No Comments »

chdir($dir); 将 PHP 的当前目录改为 $dir 。

0

怎么区分汉字和别的符号

Posted in PHP at 二月 13th, 2009 / No Comments »

汉字有两个字节,高字节   *   256   +   低字节,得到的结果在0xB0A1   于   0xD7F9(包括等于)之间,就是汉字。这是根据区位码得来得。 国标第01区       0 1 2 3 4 5 6 7 8 ...

0

PHP Content-type 的说明

Posted in PHP at 一月 13th, 2009 / No Comments »

PHP Content-type 的说明  [2007-7-14]   <?php $mimetypes = array( ‘ez’ => ‘application/andrew-inset’, ‘hqx’ => ‘application/mac-binhex40′,...