Forum Moderators: coopster
since updating to 5.1
I get an error from some files
"Only variables can be passed by reference"
It seems to be some discussions going on about that error
Looks like a bug when using array_pop() as I do within the files creating the error
But I am not sure that array_pop is the only culprit
Any ideas?
Thanks
Henry
Have you heard of anything about that bug?
So far everyone is free to find a personalized "walk around"
But why array_pop() will be somehow disallowed? Or is it really a bug?
If it is the implications are quite big for every scripts using array_po() will need modif (under 5.1).
According to another site you can "fix the problem by assigning the value to a variable before passing it to array_pop()".
array_pop($array);
but not this:
array_pop(<function which returns an array>);
IMHO the former is better coding practice anyway..