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

PHPµÄÊý¾ÝÀàÐͺÍÊý×éÏê½â


 PHPÊÇÈõÀàÐÍÓïÑÔ¡£
»ù±¾Êý¾ÝÀàÐÍ£ºinteger¡¢string¡¢boolean¡¢float
¸´ºÏÊý¾ÝÀàÐÍ£ºarray¡¢object
»ù±¾Êý¾ÝÀàÐ;Ͳ»ËµÁË£¬ÏÂÃæ¿´Ò»¸öÊý×éÏà¹ØµÄһЩÀý×Ó¡£
$test1=array(1,2,3,4);//¶¨ÒåÁËÒ»¸ö°üº¬4¸öÊýµÄÊý×é
$test1=array("new1"=>1,"new2"=>2);//Á½¸ö±äÁ¿µÄÊý×é,array['new1']=1,array['new2']=2
¶àάÊý×飺
$arr=array(array(4,3),array(3,6));ÕâÊÇÒ»¸ö¶þάÊý×é
 Êä³öÊý×éµÄ·½·¨ÓУº
print_r($arr);//´ËÖÖ·½·¨Êä³öºóΪarray([0]=>1,[1]=>2)µÄÐÎʽ
echo $arr[0];//µ¥¸öÊä³ö
ÓйØÊý×éµÄһЩº¯Êý£º
count($arr);//ͳ¼ÆÊý×éÌõÊý
is_array($arr);//ÅжÏÊÇ·ñÊý×é
explode("key",value);//ÁíÒ»ÖÖ´´½¨Êý×éµÄ·½·¨,ÏÂÃæ½øÐмòµ¥ËµÃ÷¡£

¹ØÓÚecplodeº¯ÊýµÄʹÓÃ
$a="1986-1987-1988";
$arr=explode("-",$a);//½«$aÕâ¸ö±äÁ¿ÒÔ"-"Ϊ·Ö¸îÏߣ¬²ð³ÉÊý×é²¢·ÅÈëÊý×éarrÖÐ
ÀûÓÃforeach()º¯Êý±éÀúÊý×é
$arr=(1980,1981,1982,1983,1984,1985,1986);
foreach($arr as $key=>$value){
echo $value;
echo "<br/>";
}


Ïà¹ØÎĵµ£º

PHPÃæÊÔÌâ»ã×Ü

»ù´¡Ìâ
¡¡¡¡1.±íµ¥ÖÐ getÓëpostÌá½»·½·¨µÄÇø±ð?
¡¡¡¡´ð£ºgetÓû§¶Ë½«Êý¾Ý¼Óµ½URLºó£¬¸ñʽΪ”?×Ö¶Î1=ÊäÈëÊý¾Ý1&×Ö¶Î2=ÊäÈëÊý¾Ý2&..."¡£
¡¡¡¡ÓÉÓÚgetÌá½»²ÎÊýºó»áÔÚµØÖ·À¸ÖÐÏÔʾ³öÀ´£¬ËùÒÔ»á²úÉúÑÏÖصݲȫÎÊÌâ¡£
¡¡¡¡get´«ÊäµÄÊý¾ÝÁ¿Ð¡£¬get´«ÊäµÄÊý¾ÝÁ¿Ð¡£¬ÕâÖ÷ÒªÊÇÒòΪÊÜurl³¤¶ÈÏÞÖÆ;¶øpost¿ÉÒÔ´«Ê ......

phpÈí¼þ°æ °²×° ÎÊÌâ

ÕâÁ½ÌìÒ»Ö±ÔÚ°ïÈË×ö¸öÈí¼þ¿ÉÊÇ°³Ö»»áÓÃphp£¬php³ÌÐòµÄÔËÐÐÊÇ»ùÓÚApache·þÎñÆ÷µÄ£¬Ã»°ì·¨ ÒªÔËÐгÌÐò¾Í±ØÐëÔËÐзþÎñÆ÷Apache·þÎñÆ÷¿ÉÒÔÑ¡ÓÃ×é×°°æµÄ£¬ÏÂÃæ·ÖÏíÏÂÎÒµÄÅäÖ÷½·¨£¬ÓÃÒ»¸öСµÄÅú´¦Àí³ÌÐò¾Í¿ÉÒÔÍê³É¡£
ÏÂÃæ¾ÍÊÇÎÒµÄÅú´¦Àí³ÌÐò£º
@ ECHO OFF
copy d:\road\httpd-vhosts.conf c:\xampp\apache\conf\extra  / ......

ÔõÑù²ÅÄܳÉΪPHP¸ßÊÖ£¿Ñ§»á"ÀÁ¶è"µÄ±à³Ì

      PHPÊÇһßßЧµÄÍøÂç±à³ÌÓïÑÔ£¬ÓÉÓÚËü¾ßÓбàдÁé»î¡¢ÔËÐпìËÙµÈÓŵ㣬ѸËÙ³ÉΪWeb³ÌÐòÔ±µÄÊ×Ñ¡ÓïÑÔ¡£Ç°²»¾ÃµÄÒ»·ÝȨÍþµ÷²é±íÃ÷£¬ÏÖÔÚÒѾ­ÓÐ31.6£¥µÄÍøվʹÓÃPHP×÷ΪÖ÷ÒªµÄ·þÎñÆ÷¶Ë±à³ÌÓïÑÔ¡£
¡¡¡¡µ«ÊÇ£¬Òª³ÉΪһÃûPHP±à³Ì¸ßÊÖÈ´²¢²»ÈÝÒס£²¢²»ÏñºÜ¶àÈËÏëÏóµÄÄÇÑù£¬Ö»ÒªÄܹ»·É¿ìµØ±àд ......

PHPµÄÊý¾ÝÀàÐͺÍÊý×éÏê½â

 PHPÊÇÈõÀàÐÍÓïÑÔ¡£
»ù±¾Êý¾ÝÀàÐÍ£ºinteger¡¢string¡¢boolean¡¢float
¸´ºÏÊý¾ÝÀàÐÍ£ºarray¡¢object
»ù±¾Êý¾ÝÀàÐ;Ͳ»ËµÁË£¬ÏÂÃæ¿´Ò»¸öÊý×éÏà¹ØµÄһЩÀý×Ó¡£
$test1=array(1,2,3,4);//¶¨ÒåÁËÒ»¸ö°üº¬4¸öÊýµÄÊý×é
$test1=array("new1"=>1,"new2"=>2);//Á½¸ö±äÁ¿µÄÊý×é,array['new1']=1,array['new2']=2
¶àÎ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ