Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Php error on conversion


Recommended Posts

I am getting the failure shown below while trying to import data from a V2 shop. The account is set to php 8.1. Is V4 compatible with 8.1?

Default value for parameters with a class type hint can only be NULL in /home/path-hidden/...com/install/install.class.php on line 37 

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

1 hour ago, Jack_mcs said:

I am getting the failure shown below while trying to import data from a V2 shop. The account is set to php 8.1. Is V4 compatible with 8.1?

Sure, osCommerce 4.x is compatible with PHP 8.1

1 hour ago, Jack_mcs said:

Default value for parameters with a class type hint can only be NULL in /home/path-hidden/...com/install/install.class.php on line 37 

It is not import script. It seems you are trying to run osCommerce installation under PHP 5.x

Link to comment
Share on other sites

17 hours ago, pandrei said:

It seems you are trying to run osCommerce installation under PHP 5.x

Correct. How do I convert the database of a shop that only works with those versions?

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

1 hour ago, Jack_mcs said:

Correct. How do I convert the database of a shop that only works with those versions?

Install the latest version of osCommerce v4. It requires PHP 7.4, 8.0, 8.1

Then use this manual to set up the OSC Bridge and import database: https://www.oscommerce.com/wiki/Importing_Data_from_Older_osCommerce_Version_to_New_One

Link to comment
Share on other sites

2 hours ago, pandrei said:

Install the latest version of osCommerce v4. It requires PHP 7.4, 8.0, 8.1

It is set to use 8.1.

 

2 hours ago, pandrei said:

Then use this manual to set up the OSC Bridge and import database:

The bridge is uploaded to the live shop. The live shop is using 5.4. It is the bridge code that is getting the error.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

On 3/17/2023 at 6:59 PM, Jack_mcs said:

The bridge is uploaded to the live shop. The live shop is using 5.4. It is the bridge code that is getting the error.

What error are you talking about? About this:

On 3/16/2023 at 8:53 PM, Jack_mcs said:

Default value for parameters with a class type hint can only be NULL in /home/path-hidden/...com/install/install.class.php on line 37 

It is not the OSC Bridge error. It is an osCommerce v4 installation error

On 3/17/2023 at 6:59 PM, Jack_mcs said:

The bridge is uploaded to the live shop. The live shop is using 5.4.

Are you sure you uploaded OSC Bridge and not osCommerce v4 to the live shop?

Link to comment
Share on other sites

@pandreiI'm sorry. I'm working on several conversions and got them confused. The error I posted is the correct error but it is for an installation, not a database conversion. The php version that the installation script is working with is 8.1. 

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

@pandreiAny idea when you might get to this? While waiting, I deleted all of the v4 files and tried again. Same failure. 

Unrelated to this, maybe, is that when the install file is extracted the permissions on the files are 664 so it causes a fatal error before extracting anything. 

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

10 hours ago, Jack_mcs said:

Any idea when you might get to this? While waiting, I deleted all of the v4 files and tried again. Same failure. 

I only know that you have some kind of failure at now. And it's not enough.
Could you send an error message or a screenshot of failure?

 

Link to comment
Share on other sites

4 hours ago, pandrei said:

I only know that you have some kind of failure at now. And it's not enough.
Could you send an error message or a screenshot of failure?

It's the same one I posted to open this but here it is again:

 

On 3/16/2023 at 2:53 PM, Jack_mcs said:

Default value for parameters with a class type hint can only be NULL in /home/path-hidden/...com/install/install.class.php on line 37 

That shows on the install page on the site, but only because I changed the index.php file to display errors. There are not any entries in the frontend log file. I assume you will need access for this so I will PM you with the details.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

@Jack_mcs,

Thanks for the access. It the simplest way to check your issue.

You are trying to install osCommerce v4 on PHP 5.4.45

But osCommerve v4 requires PHP 7.3 or newer

You can install on PHP 5.4.45 only OSC Bridge that allows you to export the database from osCommerce 2.x

Link to comment
Share on other sites

It turned out to be the install script replacing the .htaccess file, which removes the php version command added by cpanel.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Join the conversation

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

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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...