Results 1 to 7 of 7
  1. #1
    Join Date
    Mar 2007
    Posts
    251
    Plugin Contributions
    6

    Default SSL private cert for checkout only causing probs

    So i've altered the config files, set enable for the checkout.
    Using private cert.

    Go to the login page (still get a few probs with identifying non-secure, but will weed those out later!) and goes to https...great!

    Problem is that it changes all the links to other parts/pages of my site to https, i.e all my ez pages, and even the shop link.

    How can i stop it doing this?

    Other question is, can i turn off the display of the "search" "information"and "categories" from the side boxes during login and check out as these are still kept as http and think they casuing some of the non-secure probs.

    Thanks

    J

  2. #2
    Join Date
    Mar 2007
    Posts
    251
    Plugin Contributions
    6

    Default Re: SSL private cert for checkout only causing probs

    Ok, Solved it, thought i'd post my solution.

    In my tpl_header.php files under tmeplates, all my links were relative i.e
    '<a href="/index.html">'

    I had to change these to direct links in order that they didn't change to https when clicking on th login button.

    changed to

    '<a href="http://www.mydomain.co.uk/index.html">'

    Problem solved.

  3. #3
    Join Date
    Mar 2004
    Posts
    16,042
    Plugin Contributions
    5

    Default Re: SSL private cert for checkout only causing probs

    better solution, would be to make sure that your configure.php files are setup correctly,

    can you paste the top 30 or so lines of the includes/configure.php here
    Zen cart PCI compliant Hosting

  4. #4
    Join Date
    Mar 2007
    Posts
    251
    Plugin Contributions
    6

    Default Re: SSL private cert for checkout only causing probs

    // 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.northkites.co.uk');
    define('HTTPS_SERVER', 'https://www.northkites.co.uk');

    // 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', '/');

  5. #5
    Join Date
    Mar 2007
    Posts
    251
    Plugin Contributions
    6

    Default Re: SSL private cert for checkout only causing probs

    define('DIR_WS_HTTPS_CATALOG', '/');

    Is it the above causing it to happen?

  6. #6
    Join Date
    Mar 2004
    Posts
    16,042
    Plugin Contributions
    5

    Default Re: SSL private cert for checkout only causing probs

    no that all looks correct,
    thats weird,
    but you should never have to change the header files at all
    Zen cart PCI compliant Hosting

  7. #7
    Join Date
    Nov 2006
    Posts
    24
    Plugin Contributions
    0

    Default Re: SSL private cert for checkout only causing probs

    I'm having the same issue. I have a bunch of links in a side-box that go out of Zen Cart, but stay in my site. What I wanted was a way to use relative links, and if the current page was using SSL, turn it off.

    I wrote this ugly bit PHP code and put it near the top of my sidebox PHP file:

    PHP Code:
    <?php

      $sslStat 
    $_SERVER['HTTPS'];
      
    $currHost $_SERVER['HTTP_HOST'];
      
    $currURL $_SERVER['REQUEST_URI'];
      
    $stripURL trim($currURL"/");
      
    $currArr explode("/"$stripURL);

    function 
    makeInsecureRef($relRef)
    {
      global 
    $sslStat$currHost$currArr;
      if (
    $sslStat == "")
      {
        echo 
    $relRef;
      }
      else
      {
        
    $numURLEle count($currArr);
        
    // we don't care about the last
        // element in the array since
        // its the current file.
        
    $numURLEle $numURLEle 1;
        
    $subRelRef $relRef;
        
    $done false;
        while(!
    $done)
        {
          if (
    strcmp("../"substr($subRelRef03)) == 0)
          {
            
    $subRelRef substr($subRelRef3);
            
    $numURLEle $numURLEle 1// backing up a directory
          
    }
          else
          {
            
    $done true;
          }
          if (
    $numURLEle 0)
          {
            echo 
    "Error! " $relRef;
            return;
          }
        }
        echo 
    "http://" $currHost "/";
        for (
    $i 0$i $numURLEle$i++)
        {
          echo 
    $currArr[$i] . "/";
        }
        echo 
    $subRelRef;
      }
    }
    ?>
    The function makeInsecureRef() assembles a complete URL combining the http:// with the current host (www.mydomain.com) with as much of the current path as is required.

    Then to create the links, I call the makeInsecureRef() function this way:

    HTML Code:
    <a href="<? makeInsecureRef("../out_of_zencart.html");?>">
    This seems to work well for me.

    My question (Sorry to hijack the thread) is, where can I put this within the override system, so that ALL of my pages have access to this function? (I need to use it on my footer and header as well.)

    I hope this code is helpful and thanks in advance for some help!

    Chris

 

 

Similar Threads

  1. v154 Errors with Paypal Express Checkout (60)SSL Cert Problem/(77) error setting cert
    By jrobletto in forum PayPal Express Checkout support
    Replies: 19
    Last Post: 8 Jan 2016, 09:26 AM
  2. How to use SSL for checkout ONLY
    By hookah in forum Installing on a Linux/Unix Server
    Replies: 1
    Last Post: 22 Nov 2014, 09:55 PM
  3. share a private SSL for multiple domains
    By mydanilo in forum Installing on a Linux/Unix Server
    Replies: 18
    Last Post: 9 Mar 2010, 08:07 AM
  4. SSL Cert. and google checkout
    By nakins in forum Built-in Shipping and Payment Modules
    Replies: 1
    Last Post: 9 Oct 2007, 03:37 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg