9¸ö±ØÐëÖªµÀµÄʵÓÃPHPº¯ÊýºÍ¹¦ÄÜ
¼´Ê¹Ê¹Óà PHP ¶àÄ꣬Ҳ»áżȻ·¢ÏÖһЩδÔøÁ˽âµÄº¯ÊýºÍ¹¦ÄÜ¡£ÆäÖÐÓÐЩÊǷdz£ÓÐÓõģ¬µ«Ã»Óеõ½³ä·ÖÀûÓᣲ¢²»ÊÇËùÓÐÈ˶¼»á´ÓÍ·µ½Î²Ò»Ò³Ò»Ò³µØÔĶÁÊÖ²áºÍº¯Êý²Î¿¼£¡
1¡¢ÈÎÒâ²ÎÊýÊýÄ¿µÄº¯Êý
Äã¿ÉÄÜÒѾ֪µÀ£¬PHP ÔÊÐí¶¨Òå¿ÉÑ¡²ÎÊýµÄº¯Êý¡£µ«Ò²ÓÐÍêÈ«ÔÊÐíÈÎÒâÊýÄ¿µÄº¯Êý²ÎÊýµÄ·½·¨¡£ÒÔÏÂÊÇ¿ÉÑ¡²ÎÊýµÄÀý×Ó£º
ÒÔÏÂΪÒýÓõÄÄÚÈÝ£º // function with 2 optional arguments function foo($arg1 = '', $arg2 = '') { echo "arg1: $arg1\n"; echo "arg2: $arg2\n"; } foo('hello','world'); /* prints: arg1: hello arg2: world */ foo(); /* prints: arg1: arg2: */ÏÖÔÚÈÃÎÒÃÇ¿´¿´ÈçºÎ½¨Á¢Äܹ»½ÓÊÜÈκβÎÊýÊýÄ¿µÄº¯Êý¡£ÕâÒ»´ÎÐèҪʹÓà func_get_args() º¯Êý£º
ÒÔÏÂΪÒýÓõÄÄÚÈÝ£º // yes, the argument list can be empty function foo() { // returns an array of all passed arguments $args = func_get_args(); foreach ($args as $k => $v) { echo "arg".($k+1).": $v\n"; } } foo(); /* prints nothing */ foo('hello'); /* prints arg1: hello */ foo('hello', 'world', 'again'); /* prints arg1: hello arg2: world arg3: again */
ÍƼöÐÅÏ¢
- ¡¾ÊÓƵ²¥·Å¡¿JplayerÊÓƵ²¥·ÅÆ÷µÄʹÓÃ
- memcacheÄÚ´æÔÀí
- Memcache¼¼Êõ·ÖÏí£º½éÉÜ¡¢Ê¹Óᢴ洢¡¢Ëã·¨¡¢ÓÅ»¯....
- php³£ÓÃÕýÔò±í´ïʽ
- phpÐÔÄܼà²âÄ£¿éXHProf
- ÈÃCI¿ò¼ÜÖ§³Öservice²ã
- ʹÓÃPHPÉú³É´øLOGOµÄ¸öÐÔ»¯¶þάÂëͼÏñ
- ¹ØÓÚCodeIgniterÄã¿ÉÄܲ»ÖªµÀµÄ5¸ö֪ʶµã
- Memcache ºÁÃ뼶³¬Ê±¼°ÆäËû³£¼ûÎÊÌâ»ã×Ü
- [PHP±Ê¼Ç]PHPQueryÒ»¸ö´¦ÀíDOMµÄÀûÆ÷
ÈÈÃÅÐÅÏ¢
- nohup: redirecting stderr to stdou....
- ʹÓÃlog_formatΪNginx·þÎñÆ÷ÉèÖøüÏêϸµÄÈÕÖ¾¸ñʽ
- jquery easyUI--dataGrid-Json
- [Ô´´]·ÂGoogle Reader¡¢ÐÂÀË΢²©¡¢ÌÚѶ΢²©µ....
- ÀûÓÃKeepalived+mysql¹¹½¨¸ß¿ÉÓÃMySQLË«Ö÷×Ô¶....
- Nginx+keepalivedʵÏÖ¸ºÔؾùºâºÍË«»úÈȱ¸¸ß¿ÉÓÃ
- jqueryʵÏÖÒ³Ãæ¼ÓÔؽø¶ÈÌõ
- Rolling cURL: PHP²¢·¢×î¼Ñʵ¼ù
- codeigniter ·ÓÉÖÕ¼«ÓÅ»¯(url rewrite)
- linuxÏÂÉèÖÃsshÎÞÃÜÂëµÇ¼
×î½ü¸üÐÂ
- PHP»ñÈ¡Óû§µÄÕæʵIP£¬²¢ÅжÏÊÇ·ñÄÚÍøIP
- PHP ´íÎóÈÕÖ¾ error_log
- ÀûÓÃbigpipe»úÖÆʵÏÖÒ³ÃæÄ£¿éµÄÒì²½äÖȾ chunked¼¼Êõ
- php¿ØÖÆÎļþÏÂÔØËÙ¶È
- js + php ¶ÁÈ¡¡¢²¥·ÅÊÓƵÁ÷ ¼æÈÝfirefox£¬c....
- ¡¾ÊÓƵ²¥·Å¡¿JplayerÊÓƵ²¥·ÅÆ÷µÄʹÓÃ
- UNICODE Óë UTF-8 µÄ¹Øϵ
- memcacheÄÚ´æÔÀí
- Memcache¼¼Êõ·ÖÏí£º½éÉÜ¡¢Ê¹Óᢴ洢¡¢Ëã·¨¡¢ÓÅ»¯....
- phpʹÓÃmb_detect_encoding¼ì²â×Ö·û´®±àÂë
ÆÀÂÛ