close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 or 2018 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Shipping by Wieght

Thread began 7/11/2010 10:31 am by MikeH | Last modified 7/16/2010 11:22 am by Jason Byrnes | 1376 views | 16 replies |

MikeH

Shipping by Wieght

Hi
I have setup 3 zones for my shipping

Zone 1
Zone 2
Zone 3

Each zone has a different base rate for shipping but includes the first 15kgs but now I need to add £xx.xx per kg above that original rate.

Is there an obvious clalculation Im missing here or do I really have to add each increment up to the most you could really imaine ie 100 kgs that would take masses of rules.

Thanks for any help or pointers.

Mike

Sign in to reply to this post

Jason ByrnesWebAssist

you really only need 1 additional shipping rule to add the additional shipping.

lets say the base shipping is $20 for <= 15kg and $1 for each additional kg

Create the first rule using the trigger:
Subtotal for any column
Subtotal for column 'TotalWeight' is '>' a value of '0'

and use a flat rate calculation of 20.

For the second rule, use the trigger:
Subtotal for any column
Subtotal for column 'TotalWeight' is '>' a value of '15'



for the calculation, use:
Multiple Of Column Subtotal
Subtotal of column 'TotalWeight' 'times' '1' 'minus' '15'

Sign in to reply to this post

MikeH

Hi Jason
Thanks for the reply.

I tried that but could not get that to work and for some odd reason it show a different total on the cart page to the final confirm page.

My values are:

up to 15 kgs 26.95
Then 0.95 for every kg over

What also happens to part kg for example 15.1kg?

Thanks

Mike

Sign in to reply to this post

MikeH

Right tried again and just cannot seem to get it to come out with the correct result.

View_Cart gives a different shipping result to the confir, page details.

Either way it has not worked out the correct shipping.

Must admit a little lost with this one. I had previously tried your method before you said but to no avail.

Any other ideas appreciated.

Mike

Sign in to reply to this post

MikeH

Right theres seems to be an issue with the shipping calculations:

If using the calculation rules set out above but for each KG above the 15 you have an aditional cost of lets say 0.45p or 0.45c the shipping will not include the base charge as soon as you start working with £1 + then its ok but decimals seem to cause an issue with the calculation.

Mike

Sign in to reply to this post

Jason ByrnesWebAssist

can you send a copy of the cart php file in the WA_eCart folder so I can examine the code, it works on my system regardless of the decimal or not.

Sign in to reply to this post

MikeH

Yes sure:

I have changed some things now though was going to enter them in 1 by 1 as I couldnt get it to work.

Check the NI one when you get it that works out a little odd too :)

Mike


BTW to give an example of this in action

3 items in the cart (using Norther Ireland (NI) as the postal setting.

Weight exactly 31 kilos

so equates to

1st 15 kg = 26.95
+
16 kg at 1.15 per kilo = 18.40

Total = 45.35

Ecart = 39.35

I must admit Im lost on that.

Attached Files
eCart1_PHP.zip
Sign in to reply to this post

Jason ByrnesWebAssist

where you are charging 1.15 for each additional kg over 15, the amount =that needs to be subtracted from the Northern Ireland Over 15kg 20Supplement rule is:

1.15 * 15 = 17.25

the rule should be created as:
Subtotal of column 'TotalWeight' 'times' '1.15' 'minus' '17.25'


to be sure what the total weight in the cart is, add the following code to your page:
<?php echo WA_eCart_DisplayWeight($eCart1, $eCart1->TotalColumn("TotalWeight")); ?>

Sign in to reply to this post

MikeH

Thank you so much Jason your an absolute star. I completely missed the point until now. :)

Mike

Sign in to reply to this post

Jason ByrnesWebAssist

no worries.

Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...