Just a quick question:
Are arrays in php pass by reference?
So if I had two functions:
Should print:
The new value is: 1;
??
Are arrays in php pass by reference?
So if I had two functions:
Code:
function A($arr) { $arr[5]++; }
function B() {
$arr = array();
$arr[5] = 0;
A($arr);
echo "The new value is: ".$arr[5];
}
The new value is: 1;
??
Comment