Jump to content

Upgrade website from 7.3 to 8


Go to solution Solved by requinix,

Recommended Posts

I have a working website that I need to upgrade to php 8 or whatever is latest, Is there some kind of script or app that can be used to check my existing script and tell me what is breaking it? 

Alternatively, where can I see a list of deprecated tags that need to be changed to become compliant. 

I am not a beginner but I don't do php full time, my main job is making stuff with wood. 

Link to comment
https://forums.phpfreaks.com/topic/315884-upgrade-website-from-73-to-8/
Share on other sites

  • Solution
4 minutes ago, guymclarenza said:

Is there some kind of script or app that can be used to check my existing script and tell me what is breaking it? 

Sure: upgrade to PHP 8 and see what it complains about. Not on the real site, of course, but in some development version of it. That's really the most effective method.

4 minutes ago, guymclarenza said:

Alternatively, where can I see a list of deprecated tags that need to be changed to become compliant. 

I don't know what "tags" are, but the online documentation has migration guides.

Go through each guide in sequence; if you want to upgrade to latest, which is 8.2, then you need the 7.3->7.4 and 7.4->8.0 and 8.0->8.1 and 8.1->8.2 guides.

I don't disagree with requinix's advice here, as you need to be aware of what breaking changes are, but there are some popular tools that can help you understand the quality and inherent issues in your code.  In general, one category of these tools is "static analysis" which evaluate your source files and report on a variety of problems or things that violate best practices or a particular coding standard.  There are a number of these tools, with one of the most popular currently, being phpstan.  Depending on what editor you use, there may be a phpstan integration available that helps with evaluating and fixing problems it finds.

There's also a nice article, albeit a bit old now, about php8 migration with a lot of good information I would encourage you to check out:  https://haydenjames.io/php-8-compatibility-check-and-performance-tips/

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.