Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

Why is $free_shipping false in checkout_shipping?


Recommended Posts

I'm confused. Does OSC 2.2 have built-in support for free shipping if over a minimum amount? I have the freeamount contrib installed which seems to be working ok. checkout_shipping.php is bypassing a section for free shipping when the free shipping minimum has been satisfied.


The section checkout_shipping.php has


// load all enabled shipping modules
 require(DIR_WS_CLASSES . 'shipping.php');
 $shipping_modules = new shipping;

   $pass = false;

   $free_shipping = false;
   if ( ($pass == true) && ($order->info['total'] >= MODULE_ORDER_TOTAL_SHIPPING_FREE_SHIPPING_OVER) ) {
     $free_shipping = true;

     include(DIR_WS_LANGUAGES . $language . '/modules/order_total/ot_shipping.php');
 } else {
   $free_shipping = false;  



The problem statement is



which is always evaluating false. So $free_shipping can never get set to true, even though ($order->info['total'] >= MODULE_ORDER_TOTAL_SHIPPING_FREE_SHIPPING_OVER). So the html section for $free_shipping is not displayed.


As I said, I have freeamount installed which does display it's free shipping info, but how do the above constants get defined with a default osc install?

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.

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