Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

Table Rate By Price Limited Weight and Post Code


Recommended Posts

Hi there,

I am trying to setup my shopping cart with table rate and limited by product weight and postcode, and here is so far I can think about.


1. I setup the Table Rate charge by price,


so all orders over 49.01 will be free shipping.

2. Because I only want to offer free shipping to a small and medium size package, not the large item. I add the following code to /includes/class/shipping/ table.php




return $this->quotes;



  if (($cart->show_weight() < 50 )) {
           return $this->quotes;

This will limit the shopping cart total weight while they check out.

So, how do I change this to each item's weight instant of total cart weight?

If customer order 2 x 21 lbs item will give total weight 52 lbs, the free shipping can't apply to order.

So how can I change shopping cart total weight to heaviest items on the shopping cart's weight?



3. I also trying to limit the service only available in city area, so I will need to adding the restriction on postcode,


 if (($cart->show_weight() < 50 ) && $order->delivery['postcode'] != 'v6y 3j8')  {
           return $this->quotes;



so how can I setup multiple valuable for delivery postcode and only check if first 3 characters match?


thank you



Link to comment
Share on other sites

  • 2 weeks later...

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