摘要:<?php/*练习*/$thief = '张三';/*$GLOBALS*/function aa() { $thief = $GLOBALS['thief']; return isset($thief) ? 'yes' : 'no';}echo aa();echo '&
<?php
/*练习*/
$thief = '张三';
/*$GLOBALS*/
function aa() {
$thief = $GLOBALS['thief'];
return isset($thief) ? 'yes' : 'no';
}
echo aa();
echo '<hr>';
/*global*/
function bb() {
global $thief;
return isset($thief) ? 'yes' : 'no';
}
echo bb();
echo "<hr>";
/*传参数*/
function cc($f) {
return isset($f) ? 'yes' : 'no';
}
echo cc($thief);
						批改老师:灭绝师太批改时间:2019-01-06 16:45:45		
						
老师总结:测试比较全面,知识点重在理解,用的不多但是需要掌握!					
 
                 
 
 
  
            