dz̸php²å¼þÀ©Õ¹
×î½üÍ»·¢ÆæÏ룬.net¶¼ÓÐÃüÃû¿Õ¼ä»úÖÆ£º
using System.data;.......,
ÎÒÃÇÔÚ¿ª·¢phpʱ£¬ÊÇ·ñÒ²ÄÜʵÏÖÕâÖÖ»úÖÆÄØ£¬ÎÒÃÇÖªµÀÏÖÔÚµÄphp v5.2.9»¹²»Ö§³ÖÃüÃû¿Õ¼äµÄ¸ÅÄ
µ«Ïà¹Øphp v5.3µÄ ×ÊÁϱíÃ÷ ÒѾʹÓÃÃüÃû¿Õ¼äµÄ¸ÅÄî £º
namespace Foo
ÎÒÃÇ¿ÉÒÔ°ÑphpµÄÃüÃû¿Õ¼ä¸ÄдΪ
using ÕâÖÖ ÐÎʽÂð ^_^ ÕâÊǺó»°........
ÔÚ²âÊԵĹý³ÌÖб¾ÈË×öÁËÕâÑùÒ»¸ö²âÊÔ Ê¹ÓÃphp ½øÐÐÀ©Õ¹±àÒëµÄdll Îļþ£¨º¯Êý self_concat£© ͬÑùÊÊÓÃphp дһ¸ö»¹ÊÇ(self_concatx())
php ²¿·Ö´úÂëÈçÏ£º
<?php
function self_concat($str,$n){
$result=null;
while($n--){
$result.=$str;
}
return $result;
}
function get_microtime(){
list($usec, $sec) = explode(' ', microtime());
return ((float)$usec + (float)$sec);
}
$start=get_microtime();
echo self_concat("phpinfo()",200000);
echo get_microtime()-$start;
?>
copy phpinfo ×Ö·û´® 20W ´Ë ×ܺÄʱ¼ä£º 0.14761400222778
ʹÓà phpÀ©Õ¹ µ÷Óà self_concatx("phpinfo()",200000) ×ܺÄʱ¼ä£º0.012831926345825
ƽ¾ùʹÓÃËÙ¶ÈÒª¸ß 11.50 ±¶£¬
ͬʱ»¹×öÁËÒ»¸öСÊý¾ÝÁ¿²âÊÔ£¬·¢ÏÖ Êý¾ÝÁ¿Ô½Ð¡ ʹÓÃʱ¼äÔ½¶Ì ƽ¾ùʱ¼äÔÚ 10 ±¶ÒÔÉÏ£¡
Ïà¹ØÎĵµ£º
php°²×°
# tar xzvf php-5.2.5.tar.gz
# cd php-5.2.5
./configure --prefix=/home/redadmin/php --with-apxs2=/home/redadmin/apache/bin/apxs --with-mysql=/home/redadmin/mysql --enable-mbstring=all --enable-track-vars
# make && make install
# cp php.ini-dist /home/redadmin/php/lib/php.ini
# c ......
PhpµÄ½Å±¾¿éÓйصķûºÅ£º
1,XML·ç¸ñ£ºÅ£È˼«¶ÈÍÆ¼öµÄÓ÷¨<?php …?>¡£
2,¼ò¶Ì·ç¸ñ:<?...?>×î¼òµ¥£¬×ñÑSGML(±ê׼ͨÓñê¼ÇÓïÑÔ)´¦Àí˵Ã÷µÄ·ç¸ñ¡£ÒªÏëÓÃËü£¬Ò»¶¨Òª¿ªÆôshort_open_tagÑ¡Ï»òÕ߯ôÓö̱ê¼ÇµÄÑ¡Ïî±àÒëphp¡£(³õѧÕß¿´ÕÅÀÏʦÊÓÆµÊ±£¬¾ÍÈÝÒ×·¸Ã»ÓпªÆô¶Ì±ê¼ÇµÄ´íÎó¡£¹úÍâÅ£È˲»ÍƼö£¬µ«ÏÖÔÚ¹ú ......
ż¶û×ö¸ö¼òµ¥µÄWEB·þÎñ²âÊÔ³ÌÐò£¬ÎÒ»¹ÊÇϲ»¶²ÉÓÃPHP¡£¼ò½à£¬·ç¸ñºÍC/C++½Ó½ü£¬ÉÏÊֿ죬¶øÇÒ¿âÒ²ºÜÆëÈ«¡£ÒÔǰΪ¹ã¶«Òƶ¯×öÒÆ¶¯ÐÐÒµÖն˵ÄÑÝʾ³ÌÐòʱ£¬²ÉÓùúÄÚÒ»¸öÐÖµÜдµÄFleaPHP¿ªÔ´¿ò¼Ü£¬Á½Öܲ»µ½µÄʱ¼ä£¬ÎÒ´ÓÒ»¸ö¶ÔPHPÒ»ÎÞËùÖªµÄˮƽ£¬¿ìËٵĸ㶨ÁË30¶à¸öÒ³ÃæµÄºǫ́£¬ºóÀ´ÑÝʾЧ¹ûÒ²²»´í£¬Ò²ºÜÎȶ¨£¬´Ó´Ë¶ÔPHPÓÐÁ ......
µÚÒ»²½£º ÏÂÔØºÍ°²×°PHP
php°æ±¾: php-5.2.10-Win32.zip
1.½âѹphpÎļþµ½ c:\php
2.½«phpÎļþ¼ÐÏ php.ini-dist ¸ÄÃûΪ php.ini ,È»ºóÕÒµ½extension_dir = "./" ¸ÄΪ extension_dir = "c:\php\ext" (´ó¸ÅÔÚ461ÐÐ)
3.È¥µô;extension=php_mysql.dll ǰµÄ";"×¢ÊÍ·ûºÅ (´ó¸ÅÔÚ589ÐÐ)(Èç¹ûûÓеϰ¿ÉÒÔ¼ÓÉÏÕâÃû»°.)
4.¸´ÖÆp ......