Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Upgrading to New PHP - Conflicts?


yomama360

Recommended Posts

I understand that older versions of PHP will soon be deprecated. How hard will it be to upgrade to a newer PHP?

I'm currently running an OSC v2.3.4 (bootstrap) with PHP Version 5.3.29. Heavily modified cart.
In early 2015 we upgraded to where we are now from OSC v2.2 (and  and older version of PHP) and had tonnes of PHP issues (mysqli for example). Not really looking to do that again.

How broken will my cart get if I upgrade the PHP on my server? Is there a "safe" version of PHP I could upgrade too (even if not the latest)?
To save time/resources, I intend to leave the OSC cart as 2.3.4 (BS) unless everyone tells me it is imperative I upgrade to something else. Keep in mind I have a lot of mods, and some of them I built (hacked together) myself.

My skill level: Not a programmer, but I'm pretty good for a non-programmer. Using OSC since 2005 and have implemented a lot of mods myself.
Thanks

"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself.

Therefore, all progress depends upon the unreasonable man."

-- George Bernard Shaw

Link to comment
Share on other sites

I'm not sure about osC 2.3.4BS Gold (it's several years old, now), but for Edge, you should be able to get to the equivalent of the current release without great pain. It all depends on what "heavily modified" ends up meaning. PHP 5.3 is ancient and unsupported, so you really need to get your system up to at least 5.6, or even better, 7.0 or 7.1. You won't go through the MySQLi business again. There will be some osC code changes needed to accommodate the PHP version bump, but they should be far less painful than the last round. Of course, you kept careful track of what changes and customizations you made to your current shop, right? There are probably more add-ons available for Edge now, than when you last upgraded, so you may be able to install current add-ons rather than editing old ones, or doing full custom edits to osC.

If you are at, or can get to, the equivalent of osC 2.3.4BS Edge for your code base, you'll be good for at least PHP 7.0 and possibly 7.1 (soon?). That should hold you for several years. Not knowing what 2.3.4BS level you're actually at right now (and what your add-ons and custom work require), I can't really say what PHP version will work out of the box. If you kept good records of what you did, it may be easiest to simply install the latest 2.3.4BS Edge (on the latest PHP, up to 7.0), and repeat your changes.

PHP is constantly upgraded, obsoleting old code, and you can't simply leave your store at some install level and freeze PHP at the highest working level for that store. That's asking for trouble. Unfortunately, owning a website means frequent upgrading of your installed system and application software. The good news is that the more often you tweak it to update it, the less that needs to be done and the quicker and easier the updating is. Make it a habit to set aside a few hours several times a year, to review PHP and osC levels, and decide what you need to do. Try to stay at a supported level of PHP, and keep up your application code accordingly.

Link to comment
Share on other sites

2 hours ago, MrPhil said:

There will be some osC code changes needed to accommodate the PHP version bump,

Thanks. Is there a list or a chart somewhere that will tell me what changes?

I dont think it was Edge or Gold. If memory serves, we were live with it Jan or Feb of 2015. So I assume regular 2.3.4.  We had to get Burt to do do the bootstrap for us as it was not a package deal yet if I recall correctly.

And we did keep track of the mods. But there's a ton of them... uggh, why can't everything just be magic?
Thanks

"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself.

Therefore, all progress depends upon the unreasonable man."

-- George Bernard Shaw

Link to comment
Share on other sites

Is there an "upgrade to Edge" from 2.3.4(BS) step by step somewhere?

"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself.

Therefore, all progress depends upon the unreasonable man."

-- George Bernard Shaw

Link to comment
Share on other sites

@yomama360,

Upgrading to the latest version

EDIT: just saw that you say "from 2.3.4BS":

There are so many versions that there is no step by step guide available/possible.

You need to compare with a file comparing utility and apply the changes/replace file by file.

The one I'm using:

http://kdiff3.sourceforge.net/

 

Link to comment
Share on other sites

You said "2.3.4 (bootstrap)". Then you mentioned having Burt do some work to make it responsive. Did you install the official 2.3.4 and then have it customized to responsive? That would be a non-standard setup that should probably be replaced with something standard. @burt made an early release of 2.3.4 (official) + Bootstrap, known as "2.3.4BS Gold", but I don't think it's been updated for several years. He has put out many releases of a follow-on, "2.3.4BS Edge", which is considered the state-of-the-art production release that stores should be using.This all started in February 2014, so it's possible he installed either Gold or Edge. You'll have to figure out just what you have before you can proceed with any updating. If you have 2.3.4BS Gold or an early Edge, I think they're both good to go with up to PHP 5.6. PHP 7.0 will require an Edge upgrade, but could be worth it to get the latest features, as well as PHP 7.0 compatibility.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...