PHPµ÷ÊÔµÄÒ»°ã²½Öèѧϰ¼Ç¼
±¾ÎÄÖ»ÊÇÔÚ³¢ÊÔPHPµ÷ÊÔºó»ñµÃµÄÈô¸É¾ÑéµÄ¼Ç¼¡£
PHPµÄIDEµ÷ÊÔ¶¼±È½ÏÍ´¿à£¬Ò»°ãºÜÄÑÓм¯³ÉµÄIDE¡£ÔÚϰ¹ßÓÃMyEclipseµ÷ÊÔJSPÓ¦Óúó£¬ÔÙÈ¥¿ª·¢PHP³ÌÐò×ܾõµÃÌØ±ðÂé·³£¬Æä×î´óÔÒò¿ÉÄܾÍÊǵ÷ÊÔ»·¾³µÄ°²×°ºÍÅäÖᣱÊÕß³¢ÊÔ¹ýN´Î£¬Ê²Ã´xDebug£¬DBG Script£¬Zend Debugger£¬Í³Í³ÕûÁËÒ»±é£¬¾³£±ÀÀ£µÄ£¬Ò²·ÅÆú¹ýºÃ¼¸´Î£¬ÕætmdµÄxxx¡£ÒÔϼǼÔÚZend Studio for Eclipse ÅäÖà Zend DebuggerµÄ²½Ö裬¹©ÈÕºó²Î¿¼£¬Ò²¹©¹ý¿ÍÔÄÀÀ¡£
1£¬ÏÂÔØ Zeng Debugger
Ŀǰ(20100303)ÓÐЧµØÖ·ÊÇ£º
http://downloads.zend.com/pdt/server-debugger/ZendDebugger-5.2.14-cygwin_nt-i386.zip
ÏÂÔØµÃµ½µÄ°üÖÐÓиöREADME.txt£¬ËµµÄ±È½ÏÇå³þ£º
Zend Debugger installation instructions
---------------------------------------
1. Locate ZendDebugger.so or ZendDebugger.dll file that is compiled for the
correct version of PHP (4.3.x, 4.4.x, 5.0.x, 5.1.x, 5.2.x) in the
appropriate directory.
2. Add the following line to the php.ini file:
Linux and Mac OS X: zend_extension=/full/path/to/ZendDebugger.so
Windows: zend_extension_ts=/full/path/to/ZendDebugger.dll
Windows non-tread safe: zend_extension=/full/path/to/ZendDebugger.dll
(*) the windows non-thread safe is used only with Zend Core 2.0
3. Add the following lines to the php.ini file:
zend_debugger.allow_hosts=<ip_addresses>
zend_debugger.expose_remotely=always
4. Place dummy.php file in the document root directory.
5. Restart web server.
2£¬°´ÕÕÉÏÃæµÄ˵Ã÷£¬°ÑÏà¹Ø°æ±¾µÄdll·ÅÈëPHPµÄ°²×°Ä¿Â¼µÄextÏÂ
ZendDebugger.dllҪѡÔñÓëphp°æ±¾ÏàÆ¥ÅäµÄ
3£¬°Ñdebugger´øµÄdummy.php¸´ÖƵ½apacheÍøÕ¾¸ùĿ¼£¬dummy.phpÖ÷ÒªÓÃÀ´Óëä¯ÀÀÆ÷°²×°µÄZend Studio ToolbarͨÐÅ
4£¬ÅäÖÃphp.ini
[Zend]
zend_extension_ts=D:/PHP/ext/ZendDebugger.dll
zend_debugger.allow_hosts=127.0.0.1/32 ¡¾±¾»úIPµØÖ·/32¡¿
zend_debugger.a
Ïà¹ØÎĵµ£º
<?php
function page ( $totalPage , $currentPage,$url ,$halfPer=5)
{
$total=$totalPage-1;
$re="<td><a href="\" mce_href="\""$url\" onclick=\"page=prompt('¹²{$totalPage}Ò³\\n×Ô¶¨ÒåÌø×ªµ½µÚ¼¸Ò³£º','');if(page>0&&page<$total)location.href=this.href+'='+(page-1);r ......
¿ÉÒÔʹÓõÄÃüÁ
popen
fpassthru
shell_exec
exec
system
1.popen
resource popen
( string command, string mode )
´ò¿ªÒ»¸öÖ¸Ïò½ø³ÌµÄ¹ÜµÀ£¬¸Ã½ø³ÌÓÉÅÉÉú¸ø¶¨µÄ command
ÃüÁîÖ´Ðжø²úÉú¡£
·µ»ØÒ»¸öºÍ fopen()
Ëù·µ»ØµÄÏàͬµÄÎļþÖ¸Õ룬ֻ²»¹ýËüÊǵ¥ÏòµÄ£¨Ö»ÄÜÓÃÓÚ¶Á»òд£©²¢ÇÒ±ØÐëÓà pclose()
À´¹Ø±Õ ......
°²×°Íêphp ºÍ apacheºó£¬Èç¹ûapache ²»Ö§³Ö php
1.apacheÖÐûÓÐ php¼ÓÔØÄ£¿é¡£
ÔÚhttpd.confÖмÓÈë¡£
LoadModule php5_module "c:/php5/php5apache2_2.dll"
AddType application/x-httpd-php .php
Èç¹û ²»ÄÜÕý³£Æô¶¯apache ¿ÉÄÜÊÇapache°æ ±¾µÄÊ¡£¿ÉÒÔÐÞ¸Ä LoadModule php5_module "c:/php5/php5apache2_2.dll"
&n ......
< type="text/javascript">
smarty ¿ÉÒÔÉú³É£¬
ÆäʵÉú³ÉµÄÔÀíºÜ¼òµ¥
1¡¢»ñÈ¡Äã¶¯Ì¬Ò³ÃæµÃÄÚÈÝ
2¡¢Ð´È뾲̬Îļþ
±ÈÈ磺
<?
//»ñÈ¡ÎļþÄÚÈÝ
$content=file_get_contents(http://www.www.com/viewPage.php?id=$id
);
//¼ì²éÊÇ·ñ´æÔÚ¾ÉÎļþ£¬ÓÐÔòɾ³ý
i ......
ϵͳÉè¼Æ´ÓÒ»¿ªÊ¼¾ÍÓ¦¸Ã¿¼ÂDz»Í¬Æ½Ì¨µÄ¼æÈÝÐÔÎÊÌ⣬×î³£¼ûÒ»¸öÎÊÌâ¾ÍÊÇLinux/uniuxÓëWinµÄһЩ²»Í¬£¬±ÈÈç˵Îļþ·¾¶·Ö¸ô·û¡¢¶à¸ö·¾¢·Ö¸ô·ûµÈµÈ¡£PHP±¾ÉíÄÚÖÃÁ˺ܶೣÁ¿£¬ÔÚ·½±ãµÄ±àд´úÂëͬʱҲºÜºÃµÄ´¦ÀíºÃÁ˲»Í¬Æ½Ì¨ÏµÄһЩ¼æÈÝÐÔÎÊÌâ¡£±ÈÈç×î³£Óõģº
DIRECTORY_SEPARATOR ·¾¶·Ö¸ô·û£¬WinÏÂÊÇ"\"¶ ......