php ´úÌæ echo ·½·¨, »òÕßphpµÄ Ìæ»»Ó﷨ʹÓ÷½·¨.
ÐÞ¸Äphp.iniÎļþ.
ÈçÏÂ.
1. short_open_tag = Off
Èç¹û¸Ä³ÉOn
ÎÒÃÇ¿ÉÒÔÔÚphpÖÐ
<?= $variable?>À´´úÌæ <?php echo $variable ?>
2. asp_tags = Off
Èç¹û¸Ä³ÉOn
ͬÑù¿ÉÒÔÔÚphpÖÐ
<%= $variable %> À´Ìæ´ú<?php echo $variable ?>
ÔõôÑù. ·½±ã°É????
¼ÌÐøÑо¿~~~~~~!!!!~~!~!~!~!~!~!~!
Ïà¹ØÎĵµ£º
ÈçÏÂphp´úÂë
<?php
$type='a';
$target='type';
$a=array(1,2,3);
a($target);
function a($type)
{
global $$type;
var_dump($$type);
}
?>
Ô¤¼ÆÊä³öµÄÊÇstring(1)”a”
¿ÉÊǽá¹ûÊÇ
Notice: Undefined variable: a in D:\web\global.php on ......
ÕÒÁ˺ܶàÕâÑùµÄº¯Êý£¬»¹ÊǾõµÄÕâ¸ö×îºÃÁË
$a = 'aadfdsf¶á¶¥ÌæÒ»¿Ý»ù22245¶¥ÌæsdffhѹÏÂ';
/**
* ½ØÈ¡utf-8×Ö·û
* @param string $string
* @param int$length
*
* return string
*/
function cutstr($string, $length) {
preg_match_all("/./u", $string, $info);
$i = 0;
$str = '';
foreach($inf ......
Ç°¶Îʱ¼äÈ¥Ò»¼Ò¹«Ë¾ÃæÊÔ£¬ÓÐÒ»µÀÌâÄ¿¾ÍÊÇ£ºÔõô°Ñ¸ø¶¨µÄÒ»¸ö×Ö·û´®ÄæÐò£¬×Ö·û´®ÖаüÀ¨ÖÐÎÄ
ÓÉÓÚµ±Ê±Ã»ÓлشðÉÏÀ´£¬ºóÀ´»Øµ½ÏÈѧУÈÏÕæÏëÁËÏ£¬Ò²ÔÚÍøÉÏÕÒÁËһЩ×ÊÁÏ£¬°´ËûÃǵķ½·¨È¥ÊµÏÖ£¬¿É½á¹û¶¼ÓÐÂÒÂ룡߯ÓôÃÆ£¬ÓÖ¹ýÁË»á¶ùÏë³öÀ´ÁËÕâ¸ö·½·¨ÈçÏ£º
------------------------------------------------------------------ ......
<?
error_reporting(2047);#±¨¸æËùÓзǷ¨µÄ´íÎó
ob_start();
function RMB ($RMB=0,$Format='') {
/*
*/
$RMB=@preg_Replace(
array('/([, ]|£¤|0$|)/','/(.){2,}/'),
array('','.'),
$RMB);
if(eregi("[^0-9.]",$RMB))return "·Ç·¨½ð¶î";
if($RMB==0)retur ......
ÖÕÓڷżÙÁË£¬ÕýÏëÔÚÕâ¸ö¼ÙÆÚÀïѧѧPHP£¬ÓÉÓÚ×Ô¼ºÓõÄÊÇ×ÀÃæ°æµÄUbuntu8.04,ÓÚÊǾÍÏë¼ÜÉèÒ»¸öLAMP»·¾³À´Ñ§PHP£¬Ò²³Ã´Ë»ú»áѧһÏÂPHP·þÎñÆ÷µÄ¼ÜÉè¡£
Ò»¡¢°²×°Ubuntu8.04
ËäȻ˵ÊÇÅäÖÃLAMP»·¾³£¬µ«ÔÚÎÄÕÂÀï²¢²»»á½²ÊöÈçºÎ°²×°Ubuntu8.04,ÒòΪ¹ØÓÚÈçºÎUbuntu8.04ÔÚÍøÉÏÒѾÓкܶàµÄ½Ì³ÌÁË£¬¾ÍËãÊÇÓ²ÅÌ°²×°Ò²ÊÇÒ»¼þºÜ¼òµ¥µÄÊÂÁ ......