Post by Purebeads » Thu Nov 12, 2015 7:26 pm

My hosting company has just upgraded to a new version of PHP, and my OpenCart 1.4.8b cart is suddenly not working. The tech person I spoke to was not able to fix the problem, and he has escalated it to another department. However, he intimated that the company may not take ultimate responsibility for the issue, which would mean that my cart would be permanently broken. Does anyone have any experience with this problem? Does anyone know what changes need to be made to my files to make my site work again?

Upgrading to a later version of OpenCart isn't an option. The program has changed too much, and upgrading would be too much work.

Here is the address of my cart: http://www.purebeads.com/catalogue/

Thank you.

Active Member

Posts

Joined
Fri Apr 30, 2010 12:07 pm

Post by uksitebuilder » Thu Nov 12, 2015 11:14 pm

I believe the error you need to solve is the deprecated mysql error.

As of php 5.5 although you can still use the mysql DB driver, it has been deprecated.

Unfortunately I don’t have OC 1.4.x on our system, but I am guessing it is similar to 1.5.x

You will need to use the mysqli Db driver to get rid of this error message, which should in turn get rid of the session_start() errors as they are only caused by the deprecated mysql error being output before the session starts.

Please download the attached file and upload to your system/database folder
After uploading the file, you then need to edit your config.php file and admin/config.php file

In that file, hopefully it will say:

Code: Select all

define('DB_DRIVER', 'mysql');
You should change this to

Code: Select all

define('DB_DRIVER', 'mmysqli');

User avatar
Guru Member

Posts

Joined
Thu Jun 09, 2011 11:37 pm
Location - United Kindgom

Post by Purebeads » Fri Nov 13, 2015 3:26 am

I just got out of bed. I'll do the things you said and see what happens. Thank you for helping.

Active Member

Posts

Joined
Fri Apr 30, 2010 12:07 pm

Post by EvolveWebHosting » Fri Nov 13, 2015 5:27 am

Purebeads wrote:My hosting company has just upgraded to a new version of PHP, and my OpenCart 1.4.8b cart is suddenly not working. The tech person I spoke to was not able to fix the problem, and he has escalated it to another department. However, he intimated that the company may not take ultimate responsibility for the issue, which would mean that my cart would be permanently broken. Does anyone have any experience with this problem? Does anyone know what changes need to be made to my files to make my site work again?

Upgrading to a later version of OpenCart isn't an option. The program has changed too much, and upgrading would be too much work.

Here is the address of my cart: http://www.purebeads.com/catalogue/

Thank you.
Hi,

I can understand that you're comfortable with the 1.4.8 version but it's really hard for any hosting company to provide support to software that has reached EOL (End of Life). Opencart v1.4.8 was released about 5.5 years ago: http://forum.opencart.com/viewtopic.php?t=15699

You can try the change for the mysql driver but I strongly suggest upgrading or hiring someone like Qphoria to upgrade your store to a more recent version that is supported. Like any software, there's only so long that it can be updated and supported. The hosting company would be putting themselves and anyone else on the servers in a position to be so vulnerable and their servers along with all of the data could be wiped out.

It's not what you want to hear but it's the truth and the way software industries work.

DL

Opencart Hosting Plans, Domain Registration, Microsoft and Google Email and More
Visit our website for great deals and most importantly, fast and friendly support - www.evolvewebhosting.com


User avatar
Active Member

Posts

Joined
Fri Mar 27, 2015 11:13 pm
Location - Denver, Colorado, USA

Post by Purebeads » Fri Nov 13, 2015 6:05 am

EvolveWebHosting wrote:I can understand that you're comfortable with the 1.4.8 version but it's really hard for any hosting company to provide support to software that has reached EOL (End of Life). Opencart v1.4.8 was released about 5.5 years ago: http://forum.opencart.com/viewtopic.php?t=15699

You can try the change for the mysql driver but I strongly suggest upgrading or hiring someone like Qphoria to upgrade your store to a more recent version that is supported. Like any software, there's only so long that it can be updated and supported. The hosting company would be putting themselves and anyone else on the servers in a position to be so vulnerable and their servers along with all of the data could be wiped out.

It's not what you want to hear but it's the truth and the way software industries work.
In my view, 5.5 years is not a super-long time. My investment in version 1.4.8b is huge, and the amount of work needed to upgrade my cart would also be huge. First of all, I don't LIKE the newer version of OpenCart -- I don't like the appearance and the strange checkout procedure. Switching to another cart platform would also be a huge amount of work. I have 2,000 products in my cart, about 650 of them are inactive now, but that leaves 1,350 active products. Transferring all that stuff to a new cart would take weeks of work. The whole idea that every four or five years I must change my shopping cart is simply absurd.

My hosting company, Westhost, installs one version of PHP on every server. I have found a hosting company that allows customers to install the version they want on their individual sites. I may have to move my site to that company.

Active Member

Posts

Joined
Fri Apr 30, 2010 12:07 pm

Post by EvolveWebHosting » Fri Nov 13, 2015 1:09 pm

I understand your concerns. One other option is to look into one of the checkout extensions and then get your store software upgrade done. 1.4.x has not been supported in a long time and it will not receive any security patches or further development. I have seen plenty of sites hacked and I would hate to see that happen to you due to outdated software.

This was just a thought / suggestion I had for you.

Opencart Hosting Plans, Domain Registration, Microsoft and Google Email and More
Visit our website for great deals and most importantly, fast and friendly support - www.evolvewebhosting.com


User avatar
Active Member

Posts

Joined
Fri Mar 27, 2015 11:13 pm
Location - Denver, Colorado, USA

Post by Purebeads » Fri Nov 13, 2015 2:18 pm

Are you talking about upgrading to OC 2 and then using a module or extension?

I decided to look at the demo to see if it has improved since version 1.5, and the demo won't let me add anything to the cart, so I can't look at the checkout process. If they have changed it, maybe I'll consider upgrading.

But my point is this: I shouldn't have to upgrade so soon after installing OpenCart to begin with. It took me half a year to load all my stuff into 1.4.8, and I shouldn't have to go through that process every 5 years. Upgrading from 1.4.8 to 2 will be a lot of work, even if I'm able to use my 1.4.8 database.
Last edited by Purebeads on Fri Nov 13, 2015 7:56 pm, edited 1 time in total.

Active Member

Posts

Joined
Fri Apr 30, 2010 12:07 pm

Post by Purebeads » Fri Nov 13, 2015 7:34 pm

uksitebuilder wrote:I believe the error you need to solve is the deprecated mysql error.

As of php 5.5 although you can still use the mysql DB driver, it has been deprecated.

Unfortunately I don’t have OC 1.4.x on our system, but I am guessing it is similar to 1.5.x

You will need to use the mysqli Db driver to get rid of this error message, which should in turn get rid of the session_start() errors as they are only caused by the deprecated mysql error being output before the session starts.

Please download the attached file and upload to your system/database folder
mmysqli.php
After uploading the file, you then need to edit your config.php file and admin/config.php file

In that file, hopefully it will say:

Code: Select all

define('DB_DRIVER', 'mysql');
You should change this to

Code: Select all

define('DB_DRIVER', 'mmysqli');
Uksitebuilder, at first I didn't follow your directions because I already had a tech person at my hosting company working on the problem. (In fact, I had him look at your instructions in this thread, but he didn't follow them.) Their database guru told the tech person that he only needed to remove the error messages since the MySQLi driver could still be used. He did remove the error messages, but they persisted in the Admin area. So I applied your fix over night and the error messages disappeared from the Admin area.

Does your fix mean that my shopping cart is now compatible with PHP 5.5 (and hopefully future versions)? Do I have to worry about my site "breaking" when my hosting company upgrades to future versions of PHP?

Needless to say, I am very grateful to you. The tech people seemed somewhat befuddled by the problem, yet the fix was so simple.

Active Member

Posts

Joined
Fri Apr 30, 2010 12:07 pm

Post by uksitebuilder » Fri Nov 13, 2015 8:28 pm

To be honest, your tech guys probably don’t know how OpenCart functions.

For them to turn off the deprecated notice is not really fixing the problem per se (just hiding it).

OpenCart's coding is very good in that all database calls and connections etc are handled by one file. It is therefore easy to switch between various database drivers just by specifying the driver in the config.php files.

The file does need to exist though in the system/database folder. Hence why you had to upload the mysqli database file.

--

As far as will your site breaking when new php versions come out and your host upgrades.

When PHP is updated, some old built-in php functions get deprecated or changed. I can't speak for OC1.4.x - but OC1.5.x in its default state runs perfectly fine on php5.6

The problems arise when you have many add-ons / extensions. If the developer of those add-ons has used a php function that has been deprecated then the module/site will break.

PHP 7 is on the horizon of becoming the next stable release. (there is no php 6 as it was scrapped)

Here is a table of the php supported versions
http://php.net/supported-versions.php

It would not surprise me to see most web hosts moving to php 5.6 by mid next year as their minimum supported version

User avatar
Guru Member

Posts

Joined
Thu Jun 09, 2011 11:37 pm
Location - United Kindgom

Post by Purebeads » Sat Nov 14, 2015 4:05 am

Well, it sounds like you've given me more time than I otherwise had. My site was running fine on 5.4, and now it is running fine on 5.5 (thanks to you), so I think I should be able to get a few more years out of this cart. If the developers of PHP are smart, they will make new versions as backward-compatible as possible. This time, for some reason they decided to change the database engine, but I'm sure they won't do that with every release.

It took me a while, but I think I understand the issue now: Before they completely remove a function, they "deprecate" it so that people get error messages. My add-ons and extensions are from people who appear to have programming savvy, such as Qphoria (I got an add-on from an Indian programmer once and it was a mess; I had to delete it); so I think I'll probably be all right in that regard. I do have this option: Let's say that my site stops working on PHP 5.6, yet it is working now on 5.5, I already know that I can find a hosting company that allows customers to select their PHP version, so I should be able to have PHP 5.5 on my site for many more years.

One more question: Should I go back to my hosting company and ask them to turn the error messages back on? If I don't do that, I won't be alerted to future deprecations.

Thank you again. You saved my ass.

Active Member

Posts

Joined
Fri Apr 30, 2010 12:07 pm

Post by victorj » Sat Nov 14, 2015 4:48 am

To asure you your site will run perfect under php 5.6.

The mysql deprcation is not a php problem, but a sql problem, mysql has been free for years, and they decided to sell mysql to sun.
Some enthousiastic former mysql guyd decide to keep supporting free mysql but they changed the name to mysqli and changed some small functions under the hood to stand apart from whats now sun.

You night consider upgrading to 1.5.6.4 First off all with right theme it will suport all mobile devices, not unimportant these times.
Upgrading to 1.5 can be done relative easy using your existing database (of course you will doe the upgrade with a copy off your database in a test enviroment)

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by uksitebuilder » Sat Nov 14, 2015 4:53 am

By all means, ask them to undo what they did with regards to hiding that specific error.

It is however always a good idea to turn off error reporting (especially in OpenCart admin Settings) for a production site.

They should only be turned on to test new additions (add-ons etc) and other development. Once errors are gone, turn off error reporting. Otherwise it gives the public all your server paths etc and if you had a dodgy add-on that was not coded correctly, it could expose your DB details.

It would be in your best interests to upgrade (if not to OC 2.x) to OC 1.5.6.4 at some point soon. Why wait for the world to end before you act :-)

Get a developer to do it on a dev server or locally so that your current site is s still running until you are happy with the upgrade/functionality.

User avatar
Guru Member

Posts

Joined
Thu Jun 09, 2011 11:37 pm
Location - United Kindgom

Post by Purebeads » Sat Nov 14, 2015 5:37 am

Actually, Victor, I don't like the appearance of 1.5.6.4, and the upgrade procedure (which I investigated) is doable, but it is still a lot of work. The 1.4.x version of the cart has a pleasing, slightly old-fashioned appearance which suits my business well. Version 1.5.x appears more suited to selling electronic products or other modern items.

However, I'm curious as to how the checkout procedure in version 2 works. Is it the same as 1.5, or has it changed? The demo on this site doesn't allow me to check out. Does anyone reading this have version 2 on their site? If so, I would like to see it.

============

UKsitebuilder, I'm wondering if you might be able to tell me in which files I turn the error message on and off. I'm not a PHP programmer, so I have no idea. Perhaps the situation that I have now (where I am seeing the error messages in my Admin area only) is the best arrangement.

With 1,800 products, the work involved in upgrading my cart will be tremendous. And as I've been saying to other people here, I don't like the look of the newer versions. Also, I am 65, and if I can keep my current cart going until I am 70, I might retire then (although running a business will probably help me live longer).

Active Member

Posts

Joined
Fri Apr 30, 2010 12:07 pm

Post by victorj » Sat Nov 14, 2015 5:43 am

I agree, your looks suite your products.

There is no difference in checkout between 1.4 and 2.c, still the same steps a customer has to go through, so no major change there, i can set up a oc 2 site full functional for you to have a look, will pm you details should be up and working in 20 min

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by Purebeads » Sat Nov 14, 2015 5:49 am

victorj wrote:I agree, your looks suite your products.

There is no difference in checkout between 1.4 and 2.c, still the same steps a customer has to go through, so no major change there, i can set up a oc 2 site full functional for you to have a look, will pm you details should be up and working in 20 min
Victor, you don't have to set up a cart just for me.

I never liked the "steps", as you call them. Every other cart I use on the internet uses a series of pages for the checkout process, and that's what I like.

Active Member

Posts

Joined
Fri Apr 30, 2010 12:07 pm

Post by victorj » Sat Nov 14, 2015 5:53 am

setting up is a big word, its just in cpanel doing a install on a domain not used at the moment, it will give you a look will pm details to you

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by Purebeads » Sat Nov 14, 2015 5:55 am

Thanks.

I just realized that you said that the checkout process was the same between 1.4 and 2, but I think you meant 1.5 and 2. 1.5 is very different from 1.4.

Active Member

Posts

Joined
Fri Apr 30, 2010 12:07 pm

Post by victorj » Sat Nov 14, 2015 5:59 am

have a look yourself :-)

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by Purebeads » Sat Nov 14, 2015 6:39 am

It was very nice of you to do that for me. I have taken a quick look at it, but I have to step out. I'll investigate it more throughly and let you know what I think. Thanks!

Active Member

Posts

Joined
Fri Apr 30, 2010 12:07 pm

Post by EvolveWebHosting » Sat Nov 14, 2015 9:10 am

Purebeads wrote:Are you talking about upgrading to OC 2 and then using a module or extension?

I decided to look at the demo to see if it has improved since version 1.5, and the demo won't let me add anything to the cart, so I can't look at the checkout process. If they have changed it, maybe I'll consider upgrading.

But my point is this: I shouldn't have to upgrade so soon after installing OpenCart to begin with. It took me half a year to load all my stuff into 1.4.8, and I shouldn't have to go through that process every 5 years. Upgrading from 1.4.8 to 2 will be a lot of work, even if I'm able to use my 1.4.8 database.
Hi,

When you upgrade, you will not be manually adding your products, orders, categories, etc back into the system. All of this is carried over through the database upgrade so this process is much faster than you're probably thinking it will be.

The 2.x checkout does use 'steps' but you can easily change is with a mod similar to this one: http://www.opencart.com/index.php?route ... on_id=7382

Just wanted to pass it along.

Regards,

DL

Opencart Hosting Plans, Domain Registration, Microsoft and Google Email and More
Visit our website for great deals and most importantly, fast and friendly support - www.evolvewebhosting.com


User avatar
Active Member

Posts

Joined
Fri Mar 27, 2015 11:13 pm
Location - Denver, Colorado, USA
Who is online

Users browsing this forum: Semrush [Bot] and 19 guests