Glossary Item Box

Squirrelcart v6.1.0

v4.0.0

Overview

This page has been written as a guide to aid you in upgrading your site from v3.0.0 to v4.0.0 and after. Please read this page in its entirety before attempting to upgrade.

FedEx Web Services

In prior versions, we used a library called NuSOAP for communication with FedEx Web Services. As of version 4.0.0 we use the built-in PHP SOAP extension. If that extension is not available on your server FedEx Web Services will no longer work until that extension is enabled. 

To see if it is enabled:

  1. Login as store admin
  2. Open the phpinfo.php file in your browser, which is inside the squirrelcart folder. The URL will be like this (but with your domain name):
    http://www.example.com/squirrelcart/phpinfo.php
  3. Search the page for SOAP. If not found, you do not have the extension installed.

SEO URL changes

If you are using our SEO URLs (advanced) feature and wish to use the new Social Sign On feature, you'll need to update your .htaccess file to add support for it.

  1. Open your .htaccess file in an editor
  2. If you find a section like this:

    RewriteEngine On
    RewriteRule ^(products|categories|content|news|reviews|testimonials|contact|downloads|store-locator)/?(.*)$ store.php/$1/$2 [L]

    Add |downloads|store-locator inside the first set of parentheses, at the very end:

    RewriteEngine On
    RewriteRule ^(products|categories|content|news|reviews|testimonials|contact|downloads|store-locator|auth)/?(.*)$ store.php/$1/$2 [L]

  3. If you find a section like this:

    <Files ~ "categories|products|content|news|reviews|testimonials|contact|downloads|store-locator|auth">
    ForceType application/x-httpd-php
    </Files>


    Add |content inside the quotes, directly before the last quote:

    <Files ~ "categories|products|content|news|reviews|testimonials|contact|downloads|store-locator">
    ForceType application/x-httpd-php
    </Files>

  4. Save the file

Theme and Template Changes

If you are using a custom version of any of the below template files, make the changes outlined for the custom version of that file inside your custom theme folder (Example: squirrelcart/themes/YOURTHEMENAME). If you are not using a custom version of that file you do not need to make any changes. This section is a guide only. If a v4.0.0 template file has a lot of changes, you are probably better off reverting to the default version by removing your custom version of the same file.

If you are using a custom theme from version 3 and do not have the template file squirrelcart/themes/store_main.tpl.php inside your custom theme folder, we recommend copying that file to your custom theme folder in version 4, from your version 3.x backup. You'll find the file in your version 3 backup under squirrelcart/themes/squirrelcart/. By using this file, you will not have to make as many changes to get your older version 3 theme working in version 4.

 

product_detail.tpl.php

  1. Find this line:
    <?php print sc_msg($Out_of_Stock_Message) ?>
  2. Add this after:
    <?php if ($Sell_In_Increments > 1):?>
     <?php print sc_msg("This item must be purchased in increments of $Sell_In_Increments.")?>
    <?php endif;?>
  3. Find this:
     <?php if ($Badge_Image): ?>
      <img class="badge" src="<?php print $Badge_Image['dyn'] ?>" width="<?php print $Badge_Image['width'] ?>" height="<?php print $Badge_Image['height'] ?>" alt="" />
     <?php endif; ?>    
    </div>
  4. Add this after:
    <?php if (!empty($Extra_Images)):?>
         <div class="xtra_imgs">
              <?php foreach($Extra_Images as $Extra_Image):?>
                   <a href="<?php print $Extra_Image['dyn']?>" rel="lightbox[product-<?php print $record_number ?>]" target="_blank">
                        <img src="<?php print $Extra_Image['thumb_dyn'] ?>" alt="<?php print $Extra_Image['alt'] ?>" />
                   </a> 
              <?php endforeach;?>
         </div>
    <?php endif;?>

store_home.tpl.php

  1. Find this line:
    <?php if (isset($SC['msg_generic'])):?>
  2. Change to:
    <?php if ($Status_Message):?>
  3. Find this line:
    <?php print $SC['msg_generic'] ?>
  4. Change to this:
    <?php print $Status_Message ?>

store_main.tpl.php

  1. Find this line:
    <body>
  2. Change to:
    <body class="<?php print $SC_Body_Classes?>">
  3. Find this line:
    <div id="sc" class="cols<?php print $num_columns?>">
  4. Change to:
    <div id="sc" class="<?php print $SC_Classes ?> btn_wait_toggle">

style_main.css.php

  1. Find this:

    .nav_block_title {
     border-bottom: gray solid 1px;
     padding: 3px;
     margin-bottom: 10px;
     font-size: 16px;
    }
  2. Change to this:

    .nav_block h2.sc_title,
    .nav_block_title {
     border-bottom: gray solid 1px;
     padding: 3px;
     margin: 0 0 10px 0;
     font-size: 16px;
     font-weight: normal;
    }
  3. Find all occurrences of this selector:

    .sc_content h1
  4. Change to:

    .sc_content h1, .sc_content h2.sc_title
    Note: The ".sc_content h1" selector also appears in the old style_variant1_COLOR.css.php files. If you are using one of these stylesheets, you'll need to make the same change to it as well.
  5. Find this:

    .acct_choice .inner,
    .acct_choice_skip {
        padding: 15px;
    }
  6. Change to:

    .acct_choice .inner,
    .acct_choice_skip {
        padding: 0 15px 15px 15px;
  7. Find this:

    .acct_choice .or {
        position: absolute;
        top: -12px;
        left: 50%;
        margin-left: -13px;
        <?php if ($SC['browser']['browser'] == 'ie' && $SC['browser']['maj_ver'] <= 6.0): ?>
           /* fixes an IE bug */
           left: 0px;
        <?php endif; ?>
    }

  8. Change to:

    .acct_choice .or {
     position: absolute;
     top: -12px;
     left: 50%;
     margin-left: -15px;
     display: inline-block;
     width: 27px;
     height: 27px;
     line-height: 24px;
     border: silver solid 2px;
     border-radius: 50%;
     font-weight: bold;
     font-size: 1.1em;
     color: #000;
     background: #fff;
    }
  9. Find this:

    .acct_choice label {
     font-size: 12px;
     color: gray;
    }
  10. Change to:

    .acct_choice label {
        color: gray;
        display: inline-block;
        text-align: right;
        width: 65px;
        white-space: nowrap;
    }
    .acct_choice .login_with_both label {
        width: 60px;
    }
  11. Find this:

    .required_notice {
        float: right;
        margin-top: 5px;
    }
  12. Change to:

    .required_notice {
        text-align: center;
        margin: -5px 0 15px 0;
        color: <?php print $ini['linkColor']?>;
        display: block;
    }
  13. Add this to the end of the file:
    .xtra_imgs {
        overflow: hidden;
        width: 100%;
    }
    .xtra_imgs a {
       display: block;
       width: <?php print $SC['settings']['Extra_Image_Thumb_Width']?>px;
       height: <?php print $SC['settings']['Extra_Image_Thumb_Height']?>px;
       overflow: hidden;
       float: left;
       border: silver solid 1px;
       text-decoration: none;
       margin-right: 10px;
       margin-bottom: 10px;
    }
    .xtra_imgs a:hover {
       border-color: #000;
    }

    #sc .li_opt.qty_row td {
       border-bottom-style: dotted;
    }

    #sc .opt_li_row.qty_row td {
       border-top: 0;
       border-right: 0;
    }

    .acct_choice h4 a {
       color: blue;
    }

    .acct_choice_skip h2 {
       vertical-align: middle;
       margin-right: 15px;
       padding-top: 10px;
    }

    #sc .btn_empty_no,
    #sc .btn_empty_no:hover,
    #sc .btn_empty_yes,
    #sc .btn_empty_yes:hover {
       color: inherit;
       background: #AED2F6;
       border: gray solid 1px;
       border-radius: 12px;
       margin: 50px 0;
       padding: 3px 10px;
       box-shadow: 0 2px 5px rgba(0,0,0,.2);
    }

    #sc .btn_same_as_billing {
       margin-left: auto !important;
       margin-top: auto !important;
    }
  14. If you have any of the following files in your custom theme folder, we recommend renaming to *.OLD or moving them, which will cause the default versions of these templates to be used:

    - account_choice.tpl.php
    - account_form.tpl.php
    - account_options_nav.tpl.php
    - account_options_restricted.tpl.php
    - forgot_password_email.tpl.php
    - forgot_password_email_htm.tpl.php

There are many other changes that were made to stylesheets in version 4, but the above changes should be all that is necessary to get an older version 3 theme working.

 

 


© 2001-2017 Lighthouse Development. All Rights Reserved.