Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Shopping basket empty After SSL


daniellauxen

Recommended Posts

Hey,

I have an aging oscommerce shop. In the near future, I would like to change to something "new", but in the next six months, unfortunately, I have no capacity to change.

The shop is hosted at 1 & 1, here I pay a bit more, so that the old PHP version is maintained.

So far so good. Yesterday I found out that I do not have a valid SSL certificate. At 1 & 1, a certificate is included with what I have activated. The support has then "installed" it.

The page is now secured with a valid SSL certificate, but the shopping cart in the shop is no longer working. If I now want to add an article and click on the button "in the basket", the message comes that the basket is empty.

Do you have any idea what you can do here?

Thank you and best regards

Daniel

Link to comment
Share on other sites

Installing a certificate requires two things: the cert has to be installed on the server and the code in the shop has to be changed to properly use it. It sounds like the latter was not done. You need to change your two configure files to use the cert and add redirection code to force an ssl connection. How to do both of these are explained somewhere on this site. I don't want to go into detail here in case you already know how to do that.

 

3 hours ago, daniellauxen said:

I pay a bit more, so that the old PHP version is maintained.

You shouldn't have to.

Support Links:

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

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

5 hours ago, daniellauxen said:

I have an aging oscommerce shop. In the near future, I would like to change to something "new", but in the next six months, unfortunately, I have no capacity to change.

For "new", please consider the unofficial, but community-supported and completely up-to-date 2.3.4.1BS Edge/CE/Frozen/Final (see my signature link). This is NOT what you get from the official download page, nor from your host's installer. It will be far easier to transfer your data to this version than to another product. You need to stay reasonably current with your osC shop (or any shop, for that matter) so that you can run on current PHP levels and upgrading does not become a royal pain, from having to jump so many versions.

Quote

The shop is hosted at 1 & 1, here I pay a bit more, so that the old PHP version is maintained.

Do not get too far behind on PHP versions. Older ones are quite vulnerable to hacking. The oldest currently supported version is 5.6 (goes out of support at the end of the year). 7.2 is the current release, which Edge should support OK. However, there are limits to how recent a PHP version your version of osC will support -- likely no higher than 5.4.
 

Quote

 

So far so good. Yesterday I found out that I do not have a valid SSL certificate. At 1 & 1, a certificate is included with what I have activated. The support has then "installed" it.

The page is now secured with a valid SSL certificate, but the shopping cart in the shop is no longer working.

 

Uh, that's confusing. Did you have a working SSL and then it broke or expired? At any rate, you think you now have a working SSL cert? Have you confirmed that the domain name is the same as before (on the SSL cert)?
 

Quote

 

If I now want to add an article and click on the button "in the basket", the message comes that the basket is empty.

Do you have any idea what you can do here?

 

What has changed, besides the SSL cert? Was the PHP version upgraded at all? You should check, in case the host forgot you want an old version. Did you change from SSL only on selected pages, to SSL on all pages? Was the domain name in the cert changed (adding or dropping the "www.")? Something has changed if your cart no longer works!

Link to comment
Share on other sites

thank you very much for your answers!

At the moment I have the osCommerce version 2.2-MS2 and PHP version 5.2.17.

Before, I did not have a certificate. A few years ago, the site probably had a certificate, but this has expired and I have the site once taken over without.

My provider has issued me a certificate ".stickermogul.de" and was kind enough to integrate it for me. Since then I have problems in the admin area (the emails to the customers after changing the order status do not work any more and the described problem with the shopping cart still exists.


Here is a section of the configure file:

 

// Define the webserver and path parameters
// * DIR_FS_* = Filesystem directories (local/physical)
// * DIR_WS_* = Webserver directories (virtual/URL)
  define('HTTP_SERVER', 'http://www.stickermogul.de'); // eg, http://localhost - should not be empty for productive servers
  define('HTTPS_SERVER', 'https://www.stickermogul.de'); // eg, https://localhost - should not be empty for productive servers
  define('ENABLE_SSL', false); // secure webserver for checkout procedure?
  define('HTTP_COOKIE_DOMAIN', 'stickermogul.de');
  define('HTTPS_COOKIE_DOMAIN', 'stickermogul.de');
 

Link to comment
Share on other sites

The following are incorrect. Change them as shown. Also do the same in the other configure file. This thread has more in-depth instructions.

  define('HTTP_SERVER', 'http://www.stickermogul.de'); // eg, http://localhost - should not be empty for productive servers
  define('ENABLE_SSL', false); // secure webserver for checkout procedure?

Should be

  define('HTTP_SERVER', 'https://www.stickermogul.de'); // eg, http://localhost - should not be empty for productive servers
  define('ENABLE_SSL', true); // secure webserver for checkout procedure?

 

Support Links:

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

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Jack's fix assumes that you want HTTPS (SSL) on the entire store, and not just selected critical pages. You will also want to add a redirect in your .htaccess to force HTTPS usage and force "www." (or remove it) for the host name, in accordance with what your SSL cert specifies.

Also, you might need to change your cookie domains from

stickermogul.de

to .stickermogul.de on some servers.

osC 2.2 and PHP 5.2 are both ancient history -- don't run them for any longer than it takes to upgrade to current levels (osC 2.3.4.1BS Edge/CE and PHP 7.1+).

Link to comment
Share on other sites

Phil's correct about making the site full ssl. Being that your shop is an older version, it is doubtful that it will work that way. So you probably should not change the line starting with define('HTTP_SERVER'. I apologize for the confusion.

Support Links:

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

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...