/    Sign up×
Community /Pin to ProfileBookmark

Need help setting up flat rates in woocommerce

Hi guys!

I own a woocommerce store where I sell products based on quantity, i set min purchase quantity 18 and then 19 to 36 and so on,

For an instance

minimum order qty 18 and rate is $25 if anyone purchases 19 to 36 pcs so shipping cost would be $50, if 37 to 54 shipping cost $75. I sell in only two province like in ontario and quebec. Both provinces rates are varies.

Quebect shipping min cost $25
Ontario shipping min cost $35.

I do not know how to set it, i used short code in flat rate like 1.39*[qty] but it works as per piece cost, i do not want per piece.

I need expert advise and help what to do?

Thanks

to post a comment
PHP

5 Comments(s)

Copy linkTweet thisAlerts:
@dra600nSep 17.2016 — You can use a series of IF statements or use Switch(qty)

What I did before I hooked into the USPS Shipping API was something like:
[code]
<?
if ($qty < 10) { $shipping = $10; }
if ($qty >= 10) { $shipping = $20; }
?>

It works fine and dandy for a few items, but if you go with a lot of different products, you'll probably want to base it on weight and keep a table of Canada Post prices, or if they have an API, hook into that.
Copy linkTweet thisAlerts:
@jw911authorSep 18.2016 — Hi dra600n!

Thanks for the reply. Where did you make this change? I want to know file name and will this work as i mentioned above? I
Copy linkTweet thisAlerts:
@dra600nSep 19.2016 — That I'm not too sure - I've never used woocommerce, but a quick google search led me to this:

http://stackoverflow.com/questions/27666501/how-to-add-custom-shipping-charge-in-woocommerce

And a more detailed "how to" type of page: https://calebburks.com/customize-woocommerce-shipping-rates/

(probably more helpful for you as it seems to show different ways to do it depending on your needs)
Copy linkTweet thisAlerts:
@AlyssarelishOct 20.2020 — Image Magnifier is the best plugin for WooCommerce store. By using this plugin, you can zoom product images and set zooming features effectively and quickly, not only for gallery images which shown on carousel with wonderful transitions and side arrows, but you can use both of fancy box popup, magnify popup and with five incredible ![magnify](![src](![src](![src](src)))) lens options.
Copy linkTweet thisAlerts:
@AlyssarelishOct 20.2020 — https://codecanyon.net/item/motif-zoom-magnifier/21471487
×

Success!

Help @jw911 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.25,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...