Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

³£ÓÃPHPº¯Êý

ÕâÊÇһЩʹÓÃÆµÂʱȽϸߵĺ¯Êý£¬ÓеÄÀ´×Ô±ðÈ˵ijÌÐò......
1.²úÉúËæ»ú×Ö·û´®º¯Êý
function random($length) {
 $hash = '';
 $chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789abcdefghijklmnopqrstuvwxyz';
 $max = strlen($chars) - 1;
 mt_srand((double)microtime() * 1000000);
 for($i = 0; $i < $length; $i++) {
  $hash .= $chars[mt_rand(0, $max)];
 }
 return $hash;
}
2.½ØÈ¡Ò»¶¨³¤¶ÈµÄ×Ö·û´®
×¢£º¸Ãº¯Êý¶ÔGB2312ʹÓÃÓÐЧ
function wordscut($string, $length ,$sss=0) {
 if(strlen($string) > $length) {
               if($sss){
                      $length=$length - 3;
                      $addstr=' ...';
                }
  for($i = 0; $i < $length; $i++) {
   if(ord($string[$i]) > 127) {
    $wordscut .= $string[$i].$string[$i + 1];
    $i++;
   } else {
    $wordscut .= $string[$i];
   }
  }
  return $wordscut.$addstr;
 }
 return $string;
}
3.È¡µÃ¿Í»§¶ËIPµØÖ·
function GetIP(){
             if (getenv("http_CLIENT_IP") && strcasecmp(getenv("http_CLIENT_IP"), "unknown"))
                   $ip = getenv("http_CLIENT_IP");
             else if (getenv("http_X_FORWARDED_FOR") && strcasecmp(getenv("http_X_FORWARDED_FOR"), "unknown"))
                &nbs


Ïà¹ØÎĵµ£º

Linux Enterprise5 ÏÂ php°²×°

ǰÌ᣺ Apache ºÍ MysqlÒѾ­°²×°Íê±Ï¡£
php °æ±¾£ºphp-5.2.6.tar.gz
ÏÂÔØµØÖ·£º
 ZendOptimiter-3.3.3-linux-glibc23-i386.tar.gz
ÏÂÔØµØÖ·£º
1. Ê×ÏȰ²×°  GD¿âÈí¼þ
libxml2-2.7.2.tar.gz
ÏÂÔØµØÖ·£º
#tar -zxvf libxml2-2.7.2.tar.gz
#cd libxml2-2.7.2
#mkdir /usr/local/modules
#mkdir /usr/loc ......

PHPµÄMVCʵÏÖ

¸ÕѧPHPµÄMVC,ÍøÉÏÕÒÀ´µãÎÄÕÂѧϰ,·ÖÏíÏÂ
      ASP£¬JSP£¬PHPÊÇWEB¿ª·¢µÄÈý´ó¼¼Êõ£¬ÈýÖÖ¼¼ÊõÓÅȱµãÒ²Ôç¾ÍÓÐÈË·ÖÎö¹ýÁË¡£ÎÞ·ÇÒ²¾ÍÊÇASP¼òµ¥Ò×ÓÃÇÒÓÐmicrosoft×ö¿¿É½£¬JSP¹¦ÄÜÇ¿´óÊÇÒòΪÓÐjavaÖ§³Ö£¬PHPÔò¿ªÔ´¿çƽ̨¡£ÔÚ¹úÄÚ£¬ASPÓ¦Ó÷¶Î§×î¹ã£¬JSP·¢Õ¹ÊÆÍ·×îÃÍ£¬PHPÔò´¦ÓÚÁÓÊÆ¡£Õâ¿ÉÄÜÓë¹«Ë ......

linux 64bit _ php Ìí¼Ó tidy Ö§³Ö _ ±Ê¼Ç

# °²×°tidy
yum install tidy libtidy-devel
# ¸øphpÌí¼ÓtidyÄ£¿é
wget http://pecl.php.net/get/tidy-1.2.tgz
tar -xvzf tidy-1.2.tgz
cd tidy-1.2
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config --libdir=/usr/lib64
make
make install
echo "extension="tidy.so"" ......

¶À¼Ò£ºZendºÍRightScaleÁªÊÖ½«PHPÓ¦Óõ½ÔƼÆËã


2009-10-22 09:16
 | 
322´ÎÔĶÁ
 | 
¡¾ÒÑÓÐ0
ÌõÆÀÂÛ¡¿·¢±íÆÀÂÛ
¹Ø¼ü´Ê£ºPHP

 | ¸Ðлyvonne_826
µÄÌṩ
 | 
ÊÕ²ØÕâÆªÐÂÎÅ
ÈÕǰ£¬PHPÓïÑÔ¼°¹¤¾ß¹©Ó¦ÉÌZend
TechnologiesÐû²¼½«ÁªÊÖÔÆ¼ÆËãÓ¦ÓùÜÀíÁì¾üÆóÒµRightScale£¬°ïÖúPHP¿ª·¢Õß½øÈëÔÆ¼ÆËãµÄÓ¦Óá£RightScale½« ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ