osCommerce 4 osCommerce 4 App Shop Support Services App Shop Us
• Checkout
• Get in touch

osCommerce

The e-commerce.

# Calculate price by weight

## Recommended Posts

Dear osc team and "forumers"

Writing here to ask you about how to charge shipping cost according to weight.

Guess youre a customer so if you buy 1kg or less you pay 7.5 but if you buy 2 kg you pay 7.5 + 0,44 and if you buy 4 kg you pay 7.5 + 0.44 + 0.44 + 0.44.

First kg of weight is always 7.5 rest is add 0.44 by kg.

Any idea how to get weight of product as variable and calculate?

##### Share on other sites

• 4 weeks later...

Dear osc team and "forumers"

Writing here to ask you about how to charge shipping cost according to weight.

Guess youre a customer so if you buy 1kg or less you pay 7.5 but if you buy 2 kg you pay 7.5 + 0,44 and if you buy 4 kg you pay 7.5 + 0.44 + 0.44 + 0.44.

First kg of weight is always 7.5 rest is add 0.44 by kg.

Any idea how to get weight of product as variable and calculate?

You can get the product weight in the product table.

if product weight is more than 1 kg, then you can calculate the product weight as given flow

Example

product weight 3kg then price is

price=0;

for(i=1; i<3;i++){

if(i=1){

price= 7.5;

}else{

price=price+0.44;

}

}

Edited by ssk2k10
##### Share on other sites

Each product can have a wt held for it.

There are shipping methods that already allow you to set charges by wt.

HTH

G

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

If this post was useful, click the Like This button over there ======>>>>>.

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

×   Pasted as rich text.   Paste as plain text instead

Only 75 emoji are allowed.

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
×
• Create New...