Zen Cart Logo
Forums / Basic Configuration / SSL add to cart issue

SSL add to cart issue

Locked

Views: 1,528

Results 1 to 5 of 5
This thread is locked. New replies are disabled.
3 Aug 2009, 2:35 PM
#1
dcl15 avatar

dcl15

New Zenner

Join Date:
Aug 2009
Posts:
3
Plugin Contributions:
0

SSL add to cart issue

Hi,

I have a 1.3.8a version of Zencart installed through Fantastico, where I am using the classic template, which I have customised a bit here and there and my web host is justhost.com.

I finished the website (https://www.blackknifetactica.com) a couple of days ago and I tested it and it was working perfectly. Straight after, I decided to secure it to offer protection to my customers, so I purchased a Private SSL Certificate and a Dedicated IP address from my web host. Then I followed the procedures from https://www.zen-cart.com/tutorials/index.php?article=14 to enable SSL in Zencart. Having searched through all Zencart forums, I found out that the SSL is very specific, so when following the enabling SSL procedure I made sure that I wrote down exactly the same website name as the one written in my SSL certificate. I then checked again my website to test if everything was working ok and my shop page (https://www.blackknifetactica.com/stores) had gone white and everything was all over the place. I searched through endless questions in the forum but couldn’t find anyone with the same problem. I then thought to try to write https://www.blackknifetactica.com/stores in the enabling SSL procedure instead of https://www.blackknifetactica.com to see what happened , checked my website again and the page was back; however when I was testing trying to add an item to the cart, this didn’t work at all and hence it wasn’t even possible to get to the checkout.

I am new to all this and this is my first time trying to somehow build a website. Could anyone give me some advice on this please as to how to solve the problem? I would really appreciate it.

Thanks.

3 Aug 2009, 3:00 PM
#2
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: SSL add to cart issue

Some SSL certificates are issued to a domain and all subdomains, and some just for the domain itself. You'll need to ask. If it's the latter, the best advice I can offer would be to move Zencart to the root of your site and make it the whole site.

You have everything in both the Zencart and non-Zencart portions of your site secured, which is unecessary and will slow your site down. If you post the contents of **includes/configure.php **(removing login and password info first), we might be able to spot something.

You might search these forums for "your shopping cart is empty" for threads that deal with the add-to-cart problem.

Speaking of slowing your site down, your product images are HUGE (2Mb or bigger in file size). That makes loading your pages a two or three minute proposition. You'll need to address that right away.

3 Aug 2009, 4:06 PM
#3
dcl15 avatar

dcl15

New Zenner

Join Date:
Aug 2009
Posts:
3
Plugin Contributions:
0

Re: SSL add to cart issue

Thanks for your reply. I'll ask my web host to confirm what the SSL certificate covers.

Yes, I've noticed that the non zencart part is secured, I'm going to try and sort that out shortly along with the picture sizes. I'll check for those forum threads right now.

Here is a copy of the includes/configure.php:

// Define the webserver and path parameters
// HTTP_SERVER is your Main webserver: eg, http://www.yourdomain.com
// HTTPS_SERVER is your Secure webserver: eg, https://www.yourdomain.com
define('HTTP_SERVER', 'http://www.blackknifetactica.com/stores');
define('HTTPS_SERVER', 'https://www.blackknifetactica.com/stores');

// Use secure webserver for checkout procedure?
define('ENABLE_SSL', 'true');

// NOTE: be sure to leave the trailing '/' at the end of these lines if you make changes!
// * DIR_WS_* = Webserver directories (virtual/URL)
// these paths are relative to top of your webspace ... (ie: under the public_html or httpdocs folder)
define('DIR_WS_CATALOG', '/');
define('DIR_WS_HTTPS_CATALOG', '/');

define('DIR_WS_IMAGES', 'images/');
define('DIR_WS_INCLUDES', 'includes/');
define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
define('DIR_WS_DOWNLOAD_PUBLIC', DIR_WS_CATALOG . 'pub/');
define('DIR_WS_TEMPLATES', DIR_WS_INCLUDES . 'templates/');

define('DIR_WS_PHPBB', '/');

Thanks again for all your help.

5 Aug 2009, 4:15 PM
#4
dcl15 avatar

dcl15

New Zenner

Join Date:
Aug 2009
Posts:
3
Plugin Contributions:
0

Re: SSL add to cart issue

Hi again,

I asked my web host and I was told that my SSL certificate works correctly for https://www.blackknifetactica.com or https://www.blackknifetactica.com/stores.

The problem with “add to cart” was related to a redirect to change all requests from HTTP to HTTPS. My web host disabled the redirect for me and the problem was solved. The shopping cart now redirects all users from HTTP to HTPPS automatically when they try to log in or run check out process.

I’ve now resized all the pics of my website, what a mission!! But my site’s now running much faster.

So that’s all sorted for me for now, fingers crossed. :clap:

Thanks very much for your help.

8 Aug 2009, 8:16 PM
#5
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: SSL add to cart issue

NOTE: these settings should be changed in your
/includes/configure.php

file for your Catalog:

define('HTTP_SERVER', 'http://www.blackknifetactica.com/stores');
define('HTTPS_SERVER', 'https://www.blackknifetactica.com/stores');

should read:

define('HTTP_SERVER', 'http://www.blackknifetactica.com');
define('HTTPS_SERVER', 'https://www.blackknifetactica.com');

and these:

define('DIR_WS_CATALOG', '/');
define('DIR_WS_HTTPS_CATALOG', '/');

should read:

define('DIR_WS_CATALOG', '/stores/');
define('DIR_WS_HTTPS_CATALOG', '/stores/');

NOTE: you should then also make the similar changes for your Admin configure.php file in:
/admin/includes/configure.php