日期:2014-05-17 浏览次数:20535 次
$arr = array(1,2,3,4,5);
foreach($arr as $key => &$row) {}
foreach($arr as $key => $row) {}
var_dump($arr);
array (size=5)
0 => int 1
1 => int 2
2 => int 3
3 => int 4
4 => &int 4
$arr = array(1,2,3,4,5);
foreach($arr as $key => &$row) {}
var_dump($arr);
echo $arr[4].'<br/>';
foreach($arr as $key => $row) {
echo $arr[4].'_';
}
var_dump($arr);