Problems caused by different php versions during server migration _ php instances

Source: Internet
Author: User
After the migration is performed on the server today, the front-end can be normally displayed and called, and the Error 500 is displayed on the background. Generally, You need to view the core jump file and check the login. PHP file is not called. because login cannot be found. PHP file, it proves that there is a syntax error in this file. After the migration is performed on the server today, the foreground can be normally displayed and called, and the Error 500 is displayed when you log on to the background, in this case, you need to view the core jump file and check the login. PHP file is not called. because login cannot be found. PHP file, it proves that there is a syntax error in this file.

The error message ". Fatal error: Call-time pass-by-reference has been removed" is displayed when the server is opened.

After searching for information, I found that my original server environment was version 5.2. After I changed the server, I upgraded it to version 5.4, So I encountered a parameter passing error.

Fatal error: Call-time pass-by-reference has been removed

When PHP is upgraded to 5.5, the following error message appears during program execution.

Fatal error: Call-time pass-by-reference has been removed,

That is, the new version does not allow function calling by reference, such as getformediahod (& $ method ),

This parameter transfer method is no longer allowed and can be written during function definition.

Function getforpolichod (& $ method ){},

Call time

Getforpolichod ($ method );

The above content briefly introduces the problems that may be caused by different php versions for server migration, and hopes to help you in your future work and study.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.