Home >Backend Development >PHP Tutorial >Problems that may be caused by different PHP versions of server migration, _PHP tutorial
After the server migration today, the front desk can be displayed and called normally, but a 500 error is displayed when logging in to the background. This is generally the case. Check the core jump file every time. After checking, it is found that the login.php file is not called. Because the login.php file cannot be found, it proves that there is a syntax error in this file.
Open the server error message and find. Fatal error: Call-time pass-by-reference has been removed
After searching for information, I found that my original server environment was version 5.2. After changing the server, I upgraded to version 5.4, so a parameter transfer error occurred.
Fatal error:Call-time pass-by-reference has been removed
When PHP is upgraded to 5.5, the following error message will appear during program execution
Fatal error:Call-time pass-by-reference has been removed,
That is, the new version no longer allows the use of references when calling functions, such as getFormMethod(&$method),
This method of passing parameters is no longer allowed. You can write
when defining the function.function getFormMethod(&$method){},
When called
getFormMethod($method);
The above content briefly introduces to you the problems that may be caused by different PHP versions of server migration. I hope it will be helpful for your future work and study.