PHP×Ö·û´®²Ù×÷ÈëÃÅ
ÎÞÂÛÄÄÖÖÓïÑÔ£¬×Ö·û´®²Ù×÷¶¼ÊÇÒ»¸öÖØÒªµÄ»ù´¡£¬ÍùÍùÊǼòµ¥¶øÖØÒª¡£ÕýÏñÈË˵»°Ò»Ñù£¬Ò»°ãÓÐÐÎÌ壨ͼÐνçÃ棩£¬ÓÐÓïÑÔ£¨print ×Ö·û´®£¿£©£¬ÏÔÈ»×Ö·û´®ÄܽâÊ͸ü¶àµÄ¶«Î÷¡£PHPÌṩÁË´óÁ¿µÄ×Ö·û´®²Ù×÷º¯Êý£¬¹¦ÄÜÇ¿´ó£¬Ê¹ÓÃÒ²±È½Ï¼òµ¥£¬ÏêϸÇë²Î¿´ http://cn2.php.net/manual/zh/ref.strings.php . ÒÔϽ«¼òµ¥µÄ½²ÊöËüµÄ¹¦ÄܺÍÌØÐÔ¡£
ÈõÀàÐÍ
PHPÊÇÈõÀàÐÍÓïÑÔ£¬ËùÒÔÆäËüÀàÐ͵ÄÊý¾ÝÒ»°ã¿ÉÒÔÖ±½ÓÓ¦ÓÃÓÚ×Ö·û´®²Ù×÷º¯ÊýÀ¶ø×Ô¶¯×ª»»³É×Ö·û´®ÀàÐÍ£¬½øÐд¦Àí£¬Èç:
PHP: [Copy to clipboard]
echo substr("1234567", 1, 3);
ºÍ
PHP: [Copy to clipboard]
echo substr(123456,1, 3);
ÊÇÒ»ÑùµÄ
¶¨Òå
Ò»°ãÓÃË«ÒýºÅ»òµ¥ÒýºÅ±êʶһ¸ö×Ö·û´®¡£±ÈÈç
PHP: [Copy to clipboard]
$str = "i love u";
$str = 'i love u';
ËüÕßÁ½ÕßÊÇÓÐһЩÇø±ðµÄ¡£ºóÕß½«Ò»Çе¥ÒýºÅµÄÄÚÈݶ¼»áµ±×÷×Ö·û´¦Àí£»Ç°ÕßÔò²»È»¡£±ÈÈç
PHP: [Copy to clipboard]
$test = "iwind";
$str = "i love $test";
$str1 = 'i love $test';
echo $str; //½«µÃµ½ i love iwind
echo $str1; //½«µÃµ½ i love $test
ͬÑùµÄÒÔÏÂÁ½¸öÀý×ÓµÄÐÐΪҲ²»Ò»ÑùµÄ:
PHP: [Copy to clipboard]
echo "i love \test"; // ½«µÃµ½ i love est,ÒѾ½«\tÊÓΪתÒå
echo 'i love \test'; // ½«µÃµ½ i love \test
´Ó¶ø¿ÉÒÔ¼òµ¥ÈÏΪ˫ÒýºÅÀïµÄÄÚÈÝÊǾ¹ý“½âÊÍ”¹ýµÄ£¬µ¥ÒýºÅµÄÊÇ“Ëù¼û¼´ËùµÃ”µÄ¡£ÏÔ¶øÒ×¼û£¬Ë«ÒýºÅÐÎʽµÄ¸üΪÁé»îһЩ£¬µ±È»µ¥ÒýºÅ»áÊÊÓÃÓÚһЩÌØÊâµÄ³¡ºÏ£¬ÕâÀï¾Í²»×÷²ûÊöÁË¡£
Êä³ö
PHPÀïµÄÊä³ö×î³£ÓõÄÊÇecho,print.Á½Õ߶¼²»ÊÇÕæÕýµÄº¯Êý£¬¶øÊÇÓïÑÔ¹¹Ô죬ËùÒÔµ÷ÓÃʱ²»±ØÓÃË«À¨ºÅ£¨±ÈÈçecho("test");print("test")).ÔÚÊä³öµÄʱºòÁ½Õ߶¼¿ÉÒÔʵÏÖ¸³Öµ£º
PHP: [Copy to clipboard]
echo $str="test"; //Ò»·½ÃæÊä³ötest,Ò»·½Ãæ°Ñ"test"¸³¸ø×Ö·û´®±äÁ¿ $str
print $str="test";
Á½Õß³ýÁËÃû×Ö²»Ò»ÑùÍ⣬»¹ÊÇÓÐÆäËü
Ïà¹ØÎĵµ£º
ÓÃPHP±à³Ì£¬Ê¹Óûñȡʱ¼äµÄ´úÂ룬µ«ÊÇ»ñÈ¡µ½µÄʱ¼ä×ÜÊDZȵ±Ç°Ê±¼äÔç8¸öСʱ£¬°Ù˼²»µÃÆä½â£¬ÔÚÍøÉÏËÑË÷ÁËÏ£¬ÖÕÓÚÕÒµ½Á˽â¾ö°ì·¨£¬ÔÀ´ÊÇʱÇøÉèÖÃÎÊÌâ¡£ ½â¾ö°ì·¨Ò»£º ÔÚphp.iniÀïÉèÖà date.timezone = ʱÇø ½â¾ö°ì·¨¶þ£º ²»ÓÃÐÞ¸Äphp.inÎļþ£¬Ö±½ÓÔÚ»ñȡʱ¼äµÄ´úÂëÇ°Ãæ¼ÓÉÏ£º date_default_timezone_set('ʱÇø'); ±ÈÈ ......
ËùÐèÈí¼þÔ´´úÂë°ü£º
httpd-2.2.4.tar.gz mysql-5.0.27.tar.gz php-5.2.1.tar.bz2
freetype-2.3.2.tar.gz gd-2.0.34.tar.gz jpegsrc.v6b.tar.gz
libpng-1.2.8.tar.bz2 libxml2-2.6.24.tar.bz2 zlib-1.2.2.tar.gz
°²×°Ë³Ðò£ºapache -> mysql ......
ÉùÃ÷£º²¿ÊðDedeCMS£¬ÔÚÍøÉÏËÑÁ˺ܶà×ÊÁÏ£¬°üÀ¨Õâ¸öÂÛ̳£¬¼¸ºõûÓз¢ÏÖÔÚlinuxϲ¿ÊðµÄÏÖ³É×ÊÁÏ¿ÉÒԲο¼¡£
Ë죬×Ô¼º°ÑÕû¸ö²¿Êð¹ý³ÌÖÐһЩÖØÒªµÄµã¼Ç¼ÏÂÀ´£¬Ò»ÊÇËã×ö×Ô¼ºµÄÀͶ¯³É¹û£¬Í¬Ê±£¬ÆÚÍû¶ÔÔø¾ºÍÎÒÒ»ÑùÃÔ㣬²»ÖªÈçºÎ²¿Êð   ......
PHP±à³ÌÖо³£ÐèÒªÓõ½Ò»Ð©·þÎñÆ÷µÄһЩ×ÊÁÏ£¬ÌØ°Ñ$_SERVERµÄÏêϸ²ÎÊýÕûÀíÏ£¬·½±ãÒÔºóʹÓá£
$_server ´úÂë
1. $_SERVER['PHP_SELF'] #µ±Ç°ÕýÔÚÖ´Ðнű¾µÄÎļþÃû£¬Óë document rootÏà¹Ø¡£
2. $_SERVER['argv'] # ´«µÝ¸ø¸Ã½Å±¾µÄ²ÎÊý¡£
3. $_SERVER['argc'] # °üº¬´«µÝ¸ø³ÌÐòµÄÃüÁîÐвÎÊýµÄ¸öÊý£¨Èç¹ûÔËÐÐ ......