This article describes the reference delivery considerations for PHP function transfer values. Share to everyone for your reference, as follows:
Strict standards:only variables should be passed by reference
Online to find the information there is such a sentence:
In php5.3 above version of this problem, should also be related to the configuration of PHP, as long as the sentence to split into two sentences there is no problem. because the arguments of Array_walk are passed by reference, more than 5.3 by default can only pass specific variables, and cannot return a value through a function. Of course you can also modify the error_reporting in php.ini = E_all | E_strict, but it does not conform to the norm.
$suffix = Array_pop (Explode (".", $file _name));
Why is the higher version of this restriction?
I'll go see the function prototypes in the manual:
Mixed Array_pop (array & $array) bool Array_walk (array & $array, callable $funcname [, mixed $userdata = NULL] )
The & symbol specifies that the variable is passed in and is referenced.
Switch
$file _name_arr = Explode (".", $file _name); $suffix = Array_pop ($file _name_arr);
We can.
In fact, it's just a warning. is not a fatal error. The normal result is to be able to get. For example, it is normal to get the suffix of the file name here.
More readers interested in PHP related content can view the topic: "PHP Primer for Object-oriented programming", "PHP Math Skills Summary", "PHP operation Office Document Skills Summary (including word,excel,access,ppt)", "PHP Array ( Array), "PHP Data structure and algorithm tutorial", "PHP Programming Algorithm Summary", "PHP Regular Expression Usage Summary", and "PHP Common database Operation Skills Summary"
I hope this article is helpful to you in PHP programming.
The above describes the PHP variable reference PHP function value of the reference transfer considerations analysis, including the PHP variable reference content, I hope that the PHP tutorial interested in a friend helpful.