Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB
ÈÈÃűêÇ©£º c c# c++ asp asp.net linux php jsp java vb Python Ruby mysql sql access Sqlite sqlserver delphi javascript Oracle ajax wap mssql html css flash flex dreamweaver xml
 ×îÐÂÎÄÕ : php

ASP.NET vs. PHP£¬Äĸö¸ü¿ì£¿


ASP.NET vs. PHP£¬Äĸö¸ü¿ì£¿
http://www.infoq.com/cn/news/2009/09/aspnet-php-benchmark
×÷Õß ÕÔ劼 ·¢²¼ÓÚ 2009Äê9ÔÂ15ÈÕ ÉÏÎç5ʱ33·Ö
ÉçÇø .NET Ö÷Ìâ ÐÔÄܺͿÉÉìËõÐÔ ±êÇ© PHP, ASP.NET
½áÂÛ£º
ÎÒÃÇ¿ÉÒÔÕâôÈÏΪ£¬¶ÔÓÚ´¿´âµÄPHPÖ´ÐÐÐÔÄÜÀ´Ëµ£¬LinuxºÍWindowsÏà²îÎÞ¼¸£¬Õâ²»»á³ÉΪѡÔñLinux»òWindows×÷Ϊ²¿Êðƽ̨µÄ¾ö¶¨ÐÔÒòËØ¡£
Èç¹ûÄãÔÚ¹¹½¨Ò»¸öÓ¦ÓóÌÐò£¬ÄÇôPostgreSQL¿ÉÄÜÊǸüºÃµÄÑ¡Ôñ¡£ÒòΪËüÔÚÁ½¸öƽ̨ÉϵıíÏÖ¶¼ºÜÓÅÐã¡£
Èç¹ûÄãµÄÓ¦ÓóÌÐò±ØÐëʹÓÃMySQL£¬ÄÇôѡÔñWindows¾ÍÐèÒªÔçЩ¼Æ»®À©Õ¹ÐÔÎÊÌâÁË£¨¸öÈËÈÏΪSun²»Ì«¿ÉÄÜΪWindowsÓÅ»¯MySQLµÄÐÔÄÜ£©¡£
PHPµÄµÚÒ»¸ö°æ±¾µÄSQL ServerÇý¶¯³ÌÐòÒª±ÈMySQL»òPostpreSQLÒªÂýһЩ£¬µ«ÕâÓ¦¸Ã²»»á³ÉΪÎÊÌâ¡£µÚ¶þ¸ö°æ±¾µÄÇý¶¯Æ÷ÕýÔÚ¿ª·¢Ö®ÖУ¬Ëü»á´øÀ´ÐÔÄÜÌáÉý¡£
----»ð÷è÷ë¸öÈ˾õµÃ²»¸ÃÓûº´æÀ´±È£¬»º´æµÄ¶¼ÊǾ²Ì¬Ò³Ã棬ÔÚ´óÁ¿ÍøÕ¾·ÃÎÊÏÂÓÐÓ㬵«ÊDZȽ϶¯Ì¬ÔËËãËٶȱȻº´æûÓÐÒâÒåµÄ
ÉϸöÔÂJoe StagnerÔÚ²©¿ÍÉÏ·¢±íÁËһϵÁÐÎÄÕ±ȽÏÁËPHPºÍASP.NETµÄÖ´ÐÐÐÔÄÜ£¬ÒýÆðÁËÀ´×ÔË«·½³ÌÐòÔ±µÄ´óÁ¿»ØÓ¦¡£Joe±íʾ£¬Ëû»á½«ÕâÑùµÄ²âÊÔ³ÖÐøÏÂÈ¥£¬²¢Ñ°Çó¸üΪºÏÊʵķ½Ê½£¬ÒÔ»ñµÃ¶ ......

ASP.NET vs. PHP£¬Äĸö¸ü¿ì£¿


ASP.NET vs. PHP£¬Äĸö¸ü¿ì£¿
http://www.infoq.com/cn/news/2009/09/aspnet-php-benchmark
×÷Õß ÕÔ劼 ·¢²¼ÓÚ 2009Äê9ÔÂ15ÈÕ ÉÏÎç5ʱ33·Ö
ÉçÇø .NET Ö÷Ìâ ÐÔÄܺͿÉÉìËõÐÔ ±êÇ© PHP, ASP.NET
½áÂÛ£º
ÎÒÃÇ¿ÉÒÔÕâôÈÏΪ£¬¶ÔÓÚ´¿´âµÄPHPÖ´ÐÐÐÔÄÜÀ´Ëµ£¬LinuxºÍWindowsÏà²îÎÞ¼¸£¬Õâ²»»á³ÉΪѡÔñLinux»òWindows×÷Ϊ²¿Êðƽ̨µÄ¾ö¶¨ÐÔÒòËØ¡£
Èç¹ûÄãÔÚ¹¹½¨Ò»¸öÓ¦ÓóÌÐò£¬ÄÇôPostgreSQL¿ÉÄÜÊǸüºÃµÄÑ¡Ôñ¡£ÒòΪËüÔÚÁ½¸öƽ̨ÉϵıíÏÖ¶¼ºÜÓÅÐã¡£
Èç¹ûÄãµÄÓ¦ÓóÌÐò±ØÐëʹÓÃMySQL£¬ÄÇôѡÔñWindows¾ÍÐèÒªÔçЩ¼Æ»®À©Õ¹ÐÔÎÊÌâÁË£¨¸öÈËÈÏΪSun²»Ì«¿ÉÄÜΪWindowsÓÅ»¯MySQLµÄÐÔÄÜ£©¡£
PHPµÄµÚÒ»¸ö°æ±¾µÄSQL ServerÇý¶¯³ÌÐòÒª±ÈMySQL»òPostpreSQLÒªÂýһЩ£¬µ«ÕâÓ¦¸Ã²»»á³ÉΪÎÊÌâ¡£µÚ¶þ¸ö°æ±¾µÄÇý¶¯Æ÷ÕýÔÚ¿ª·¢Ö®ÖУ¬Ëü»á´øÀ´ÐÔÄÜÌáÉý¡£
----»ð÷è÷ë¸öÈ˾õµÃ²»¸ÃÓûº´æÀ´±È£¬»º´æµÄ¶¼ÊǾ²Ì¬Ò³Ã棬ÔÚ´óÁ¿ÍøÕ¾·ÃÎÊÏÂÓÐÓ㬵«ÊDZȽ϶¯Ì¬ÔËËãËٶȱȻº´æûÓÐÒâÒåµÄ
ÉϸöÔÂJoe StagnerÔÚ²©¿ÍÉÏ·¢±íÁËһϵÁÐÎÄÕ±ȽÏÁËPHPºÍASP.NETµÄÖ´ÐÐÐÔÄÜ£¬ÒýÆðÁËÀ´×ÔË«·½³ÌÐòÔ±µÄ´óÁ¿»ØÓ¦¡£Joe±íʾ£¬Ëû»á½«ÕâÑùµÄ²âÊÔ³ÖÐøÏÂÈ¥£¬²¢Ñ°Çó¸üΪºÏÊʵķ½Ê½£¬ÒÔ»ñµÃ¶ ......

php strip_tagsº¯Êý

strip_tags
È¥µô HTML ¼° PHP µÄ±ê¼Ç¡£
Óï·¨: string strip_tags(string str);
·µ»ØÖµ: ×Ö·û´®
±¾º¯Êý¿ÉÈ¥µô×Ö·û´®Öаüº¬µÄÈκΠHTML ¼° PHP µÄ±ê¼Ç×Ö·û´®¡£ÈôÊÇ×Ö·û´®µÄ HTML ¼° PHP ±êÇ©Ô­À´¾ÍÓÐ´í£¬ÀýÈçÉÙÁË´óÓڵķûºÅ£¬ÔòÒ²»á·µ»Ø´íÎ󡣶ø±¾º¯ÊýºÍ fgetss() ÓÐ×ÅÏàͬµÄ¹¦ÄÜ
//×¢
strip Ó¢[strip]
vi. 1. ÍѹâÒ·þ
vt. 1. °þÈ¥, ÍÑÈ¥2. °þ¶á, ¶á×ß ......

PHPÑéÖ¤ÍøÒ³ÊÇ·ñ¿ÉÓõÄһЩ·½·¨

×î½ü¹«Ë¾ÓиöÍøÕ¾ÒªÏÈÅжϷþÎñÆ÷ÉϵÄÍøÒ³ÊÇ·ñ¿ÉÓã¬È»ºóÔÚ°ÑÖµÌá½»µ½Õâ¸öÍøÒ³ÉÏ¡£Ê¹ÓÃphpÀ´¼ì²âÍøÒ³ÊÇ·ñ¿ÉÓã¬Ã»Ôõô½Ó´¥¹ýphp£¬¸ãÁËÁ½Ì죬»ù±¾ÉÏÊÇ¿ÉÒÔ¼ì²âÁË¡£ÏÖ°Ñ´úÂëÌùÉÏ£º
 <?php 
  //
  $url = "http://blog.csdn.net/xuezhongsong/archive/2009/09/17/4561488.aspx";  
  $ctx = stream_context_create(array('http' => array('timeout' => 10)));  
  //»ñÈ¡ÍøÒ³ÄÚÈÝ
  $result = @file_get_contents($url, 0, $ctx);  
  if($result){  
  echo "<Script language='JavaScript'> alert('³É¹¦£¡');</Script>";
   
  }else{  
  echo "<script>alert('·þÎñÆ÷·±Ã¦£¬ÇëÉÔºóÔÙÊÔ!'); </script>";
  }  
  //ÒÔÏÂÊÇÁíÒ»ÖÖ·½·¨ÅжϷþÎñÆ÷ÍøÒ³ÊÇ·ñÏìÓ¦£¬µ«Êǵ±±¾Ò³´¦Àíʱ¼ä³¬Ê±»áÓеãÎÊÌâ¡£
  /*$fp = fsockopen("localhost", 80, &$errno, &$errstr, 10);
  socket_set_timeout($fp, 0, 10);
  if(!$fp && socket_set_timeout($fp, ......

phpÖÐsession¹ýÆÚµ«¼Ç¼²¢²»É¾³ýµÄÔ­Òò


Ç°Ò»ÕóдÁËÒ»¸ö¼òµ¥µÄÀ࣬½«session´æÈëÊý¾Ý¿â£¬µ±session_destroy()ʱ»á½«¿âÖеÄsession¼Ç¼ɾ³ý£¬¶ø¹ýÁËmaxlifetimeʱsession¼Ç¼ȴ»¹ÔÚ£¬µ±Ê±ºÜ²»Àí½â¡£
½ñÌìÓÖ¿´ÁËÏÂphp.ini£¬ÕÒµ½Á˹ØÓÚsessionµÄÅäÖã¬Ã÷°×ÁËÔ­Òò¡£
; Define the probability that the 'garbage collection' process is started
; on every session initialization.
; The probability is calculated by using gc_probability/gc_divisor,
; e.g. 1/100 means there is a 1% chance that the GC process starts
; on each request.
session.gc_probability = 1
session.gc_divisor     = 1000
ÒÔÉÏÊÇĬÈÏÅäÖã¬Ò²¾ÍÊÇsession³õʼ»¯µÄʱºòÖ»ÓÐ1/1000µÄ¸ÅÂÊÆô¶¯GC process£¬Õâ¾ÍÊÇÔ­ÒòËùÔÚ¡£
¸Ä±äÅäÖÃÈçÏ£º
session.gc_probability = 1
session.gc_divisor     = 1
ÔÙÊÔÑéһϣ¬Êý¾Ý¿âÖг¬ÆÚµÄsession¼Ç¼ÿ´Î¶¼»áɾ³ýÁË£¬³É¹¦¡£
......

linux·þÎñÆ÷°²×°£¨centos5.3 apache php mysql£©

 ×î½ü×°Á˼¸´Îlinux£¬Ñ§Á˺ܶ࣬°Ñ¹ý³ÌдÏÂÀ´ÁË£¬Ï£Íû¸ø¿´µÄÈË°ïÖú£¬Ò²¶à¸øЩ½¨Òé¡£
Ò»¡¢Ñ¡Ôñ×îС»¯°²×°£¨Ê²Ã´Ò²²»Ñ¡£¬µ«ÊÇ»¹ÊÇÑ¡ÁËvim£©
¶þ¡¢Ê¹ÓùâÅÌ×÷ΪԴ°²×°£¨ÏêÇé²Î¼û/etc/yum.repos.d/CentOS-Media.repo£©ËùÓÃÌ×¼þ£¨Ê¹ÓÃyumµÄÇ¿´ó¹¦ÄÜ£©
####²¢²»ÊǼòµ¥µÄÓÃyumÃüÁÐèÒªÔÚyumºóÃæ¼ÓһЩ¶«Î÷£¬/etc/yum.repos.d/CentOS-Media.repoÀïÃæ˵Ã÷ÁË¡£
1.°²×°wget£¬man
yum install wget£¨±È½ÏÊìϤµÄ£©
2.°²×°cron
yum list | grep ''£¨²»Ì«ÊìϤ£©
yum install vixie-cron.i386
3.°²×°apache,php,mysql
£¨¿´ÁËÍøÉÏһЩ×ÊÁÏ£¬ÓеÄÊÇ×Ô¼º±àÒëµÄ£¬¿´ÁËcentosµÄÍøÕ¾£¬½¨ÒéʹÓÃyum°²×°£¬Õâ¸öÊǺÍredhatÒ»ÑùµÄ°æ±¾£¬Èç¹ûÒ»¶¨ÒªÊ¹ÓÃа汾£¬¿É²Î¿¼
http://wiki.centos.org/HowTos
/PHP_5.1_To_5.2?highlight=%28php%29|%28mcrypt%29£©
ÎÒÊÇÒÔ¹âÅÌ×÷ΪԴÓÃyum°²×°µÄ
1)
yum list | grep 'httpd'
yum install *****
2)
yum list | grep 'php' (ÓкܶàphpÀ©Õ¹)
yum install *****(Ñ¡Ôñ×Ô¼º°²×°µÄ£¬Ö§³ÖͨÅä·û)
3£©
yum list | grep 'mysql'
yum install *****
mysqladmin -u root -p 'yourpassword'£¨¸ømysqlÉèÃÜÂ룩
ÉèÖÿª»úÆô¶¯£º
chkconfig --level 35 ......

linux·þÎñÆ÷°²×°£¨centos5.3 apache php mysql£©

 ×î½ü×°Á˼¸´Îlinux£¬Ñ§Á˺ܶ࣬°Ñ¹ý³ÌдÏÂÀ´ÁË£¬Ï£Íû¸ø¿´µÄÈË°ïÖú£¬Ò²¶à¸øЩ½¨Òé¡£
Ò»¡¢Ñ¡Ôñ×îС»¯°²×°£¨Ê²Ã´Ò²²»Ñ¡£¬µ«ÊÇ»¹ÊÇÑ¡ÁËvim£©
¶þ¡¢Ê¹ÓùâÅÌ×÷ΪԴ°²×°£¨ÏêÇé²Î¼û/etc/yum.repos.d/CentOS-Media.repo£©ËùÓÃÌ×¼þ£¨Ê¹ÓÃyumµÄÇ¿´ó¹¦ÄÜ£©
####²¢²»ÊǼòµ¥µÄÓÃyumÃüÁÐèÒªÔÚyumºóÃæ¼ÓһЩ¶«Î÷£¬/etc/yum.repos.d/CentOS-Media.repoÀïÃæ˵Ã÷ÁË¡£
1.°²×°wget£¬man
yum install wget£¨±È½ÏÊìϤµÄ£©
2.°²×°cron
yum list | grep ''£¨²»Ì«ÊìϤ£©
yum install vixie-cron.i386
3.°²×°apache,php,mysql
£¨¿´ÁËÍøÉÏһЩ×ÊÁÏ£¬ÓеÄÊÇ×Ô¼º±àÒëµÄ£¬¿´ÁËcentosµÄÍøÕ¾£¬½¨ÒéʹÓÃyum°²×°£¬Õâ¸öÊǺÍredhatÒ»ÑùµÄ°æ±¾£¬Èç¹ûÒ»¶¨ÒªÊ¹ÓÃа汾£¬¿É²Î¿¼
http://wiki.centos.org/HowTos
/PHP_5.1_To_5.2?highlight=%28php%29|%28mcrypt%29£©
ÎÒÊÇÒÔ¹âÅÌ×÷ΪԴÓÃyum°²×°µÄ
1)
yum list | grep 'httpd'
yum install *****
2)
yum list | grep 'php' (ÓкܶàphpÀ©Õ¹)
yum install *****(Ñ¡Ôñ×Ô¼º°²×°µÄ£¬Ö§³ÖͨÅä·û)
3£©
yum list | grep 'mysql'
yum install *****
mysqladmin -u root -p 'yourpassword'£¨¸ømysqlÉèÃÜÂ룩
ÉèÖÿª»úÆô¶¯£º
chkconfig --level 35 ......

linux·þÎñÆ÷°²×°£¨centos5.3 apache php mysql£©

 ×î½ü×°Á˼¸´Îlinux£¬Ñ§Á˺ܶ࣬°Ñ¹ý³ÌдÏÂÀ´ÁË£¬Ï£Íû¸ø¿´µÄÈË°ïÖú£¬Ò²¶à¸øЩ½¨Òé¡£
Ò»¡¢Ñ¡Ôñ×îС»¯°²×°£¨Ê²Ã´Ò²²»Ñ¡£¬µ«ÊÇ»¹ÊÇÑ¡ÁËvim£©
¶þ¡¢Ê¹ÓùâÅÌ×÷ΪԴ°²×°£¨ÏêÇé²Î¼û/etc/yum.repos.d/CentOS-Media.repo£©ËùÓÃÌ×¼þ£¨Ê¹ÓÃyumµÄÇ¿´ó¹¦ÄÜ£©
####²¢²»ÊǼòµ¥µÄÓÃyumÃüÁÐèÒªÔÚyumºóÃæ¼ÓһЩ¶«Î÷£¬/etc/yum.repos.d/CentOS-Media.repoÀïÃæ˵Ã÷ÁË¡£
1.°²×°wget£¬man
yum install wget£¨±È½ÏÊìϤµÄ£©
2.°²×°cron
yum list | grep ''£¨²»Ì«ÊìϤ£©
yum install vixie-cron.i386
3.°²×°apache,php,mysql
£¨¿´ÁËÍøÉÏһЩ×ÊÁÏ£¬ÓеÄÊÇ×Ô¼º±àÒëµÄ£¬¿´ÁËcentosµÄÍøÕ¾£¬½¨ÒéʹÓÃyum°²×°£¬Õâ¸öÊǺÍredhatÒ»ÑùµÄ°æ±¾£¬Èç¹ûÒ»¶¨ÒªÊ¹ÓÃа汾£¬¿É²Î¿¼
http://wiki.centos.org/HowTos
/PHP_5.1_To_5.2?highlight=%28php%29|%28mcrypt%29£©
ÎÒÊÇÒÔ¹âÅÌ×÷ΪԴÓÃyum°²×°µÄ
1)
yum list | grep 'httpd'
yum install *****
2)
yum list | grep 'php' (ÓкܶàphpÀ©Õ¹)
yum install *****(Ñ¡Ôñ×Ô¼º°²×°µÄ£¬Ö§³ÖͨÅä·û)
3£©
yum list | grep 'mysql'
yum install *****
mysqladmin -u root -p 'yourpassword'£¨¸ømysqlÉèÃÜÂ룩
ÉèÖÿª»úÆô¶¯£º
chkconfig --level 35 ......

phpÏîÄ¿¿ò¼ÜÉè¼Æ

Ò»¡¢¸ÅÊö
ÒòΪ×î½üСÏîÄ¿±È½Ï¶à£¬¶øÇÒÏîÄ¿Ö®¼äµÄÖظ´¶ÈÓֱȽϴó£¬ËùÒÔ¸ãÁËÒ»¸öÏîÄ¿¿ò¼ÜËƵĶ«Î÷£¬±ß×ö±ßÐ޸ġ£
Ä¿Ç°ÀïÃæÒѾ­ÈÝÄÉÁ˲»ÉÙ¼¸¸öÏîÄ¿£¬Ò²¸ãÁËЩÀàËÆ»ù´¡¹¹¼þÒ»ÑùµÄ¶«Î÷£º
flykobe@105 quick $ ls -FX
 inc/      jzj/  m2/      mstatic/  t/     template/  webtools/    robots.txt*
default/  jbft_v2/  m/    modsky/  nba/      env_setting.inc*  dispatch.php*  clean.sh*
×ÓÏîÄ¿µÄ½á¹¹£º
flykobe@105 quick $ ls modsky/ -FX
control/  inc/  layout/  view/
ËùÓеÄURL¶¼¾­¹ýdispatch.phpµÄ·ÓÉ£¬¾­¹ýÒ»¶¨µÄ×Ö·û´®´¦Àí¹æÔò£¬Ö¸¶¨µ½×ÓÏîÄ¿controlÖеÄij¸öÎļþÉÏÈ¥¡£
¸ùĿ¼Ï£¬ÓÐһЩ¹«¹²µÄĿ¼£º
incÊÇÈ«ÌåÏîÄ¿¹«Óõĺ¯Êý¿â
mstaticÊÇһЩÁÙʱµÄcss¡¢jsÎļþÉú³ÉºóµÄ´æ·ÅλÖÃ
tÊDzâÊÔĿ¼
templateÊǹ«¹²Ä£¿é¿â
defaultÊÇһЩĬÈÏ·¾¶£¬ÆäÖаüÀ¨ÁËÏîÄ¿¹«¹²µÄajax½Ó¿Ú£¨µ±È»£¬Ã¿¸öÏîÄ¿Ò²¿ÉÒÔ¿ª·¢×Ô¼ºµÄajax½Ó¿Ú£©
ÁíÍ⣬env_setting.incÊÇÕû¸öÏîÄ¿µÄÅäÖÃÎļþ¡£
¶þ¡¢dispatch˵Ã÷
¿ªÊ¼µÄÏë·¨ÊÇ£¬ ......
×ܼǼÊý:2174; ×ÜÒ³Êý:363; ÿҳ6 Ìõ; Ê×Ò³ ÉÏÒ»Ò³ [346] [347] [348] [349] 350 [351] [352] [353] [354] [355]  ÏÂÒ»Ò³ βҳ
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ