易截截图软件、单文件、免安装、纯绿色、仅160KB

PHP的时区问题

装了PHP-5.3.0, 启动的时候总是会有
"[06-Aug-2009 13:27:31] PHP Warning:  PHP Startup: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Asia/Chongqing' for 'CST/8.0/no DST' instead in Unknown on line 0
在lib.ini中设置date.timezone = "Asia/Shanghai", 也没有什么用...
最后在shell中执行TZ='Asia/Shanghai'; export TZ , 重启php-fpm, 解决了..


相关文档:

PHP 判断是否低俗图片==是否@色@情@图@片

if(validatorImage("d:\b.jpg"))
echo '是个低俗图片<br />';
else
echo '不是低俗图片<br />';
function validatorImage($fileName){
$image = getImage($fileName);
$width = ImagesX($image);
$height = ImagesY($image);
$ycb = 0;
for($y=0;$y<$height;$y++){
for($x=0;$x<$widt ......

PHP数据结构——线性表的删除

function delete_array_element($arr,$i) {
$len = count($arr);
for($j=$i; $j<$len; $j++) {
$arr[$j] = $arr[$j+1];
}
array_pop($arr);//将数组的最后一个单元弹出
return $arr;
}
for($i=0; $i<10; $i++) {
$arr1[$i] = $i+1;
}
print_r($arr1);
echo "< ......

PHP数据结构——冒泡排序与快速排序的比较

//冒泡排序(数组中实现)
function bubble_sort($arr) {
$cnt = count($arr);
if($cnt<=0) return false;
for($i=0; $i<$cnt;$i++) {
for($j=$cnt-1; $j>$i;$j--) {
if($arr[$j]<$arr[$j-1]) {
$tmp = $arr[$j];
$arr[$j] = $arr[$j ......

php 官网介绍

每个人都知道php.net,我们或早或晚的都会来到这里并不断的访问它。它是PHPer的主要参考网站,拥有大量有用的信息,但是这些信息却不是那么显而易见。
比较有用的官方PHP资源:
PHP官方函数手册下载: http://www.php.net/download-docs.php
 包含最新的chm中文版本,HTML版本
中文函数手册:http://www.php.net/m ......

php urlencode()

在PHP中有urlencode()、urldecode()、rawurlencode()、rawurldecode()这些函数来解决网页
URL编码解码问题。
在ASP的时候URL编码解码很是恼火,Server.urlencode不太好用,遇到utf-8编码的地址更是麻
烦。你要获取百度、Google点击到网站的网址链接中的关键字,要写上一堆自定义函数来得到urldecode的效果。
摘录一篇关 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号