Contributions
TNT Australia Shipping based on postcode
This mod for 2.2 CVS. Current as of July 2004.
It's a modified version of Lloyd Swadling's Toll courier rates. This mod is now for TNT Australia. Changes as follows:
1. Rewritten the entire postcode files to include all current postcodes AND changed all zones to TNT zones
2. Added in an initial consignment charge depending upon what zone goods are being sent to.
3. Changed shipping charge calculation to the following:
total shipping = {[x * (y - 15) + z]*1.10 * a}+ b
where:
x= charge per kilo over 15kg (changed in sql table)
y= total weight (I have deducted 15 kg from this because weight charge is only over 15kg) (total weight derived from product listing)
z= consignment charge (changed in sql table)
a= surchage factor (default 1.1)
b= handling fee (changed in oscommerce admin)
and the 1.10 bit is for GST
You don't need to download any other versions, this version will work by itself.
BUGS:
2. The only big bug I have is in the php file in catalogincludesmodulesshipping. On line 90 I have the equation to calculate the final shipping cost. However if the product weight is LESS than 15kg, you will receive an incorrect shipping calculation (try it yourself in the equation above). Unfortunately my programming skills aren't very good at all so if anyone knows the correct syntax for an IF statement would you be able to help out please? Basically to say the following:
IF product weight (y) is LESS than 15 then perform following equation:
{[z]*1.10 * a}+ b
IF product weight is 15 kg or MORE then perform following equation:
{[x * (y - 15) + z]*1.10 * a}+ b
Expand All / Collapse All
This file is simply an update of the SQL table to reflect rates for stores sending from Brisbane (BNE)
Only the SQL file is attached. Everything else relies on the V3 version of the contribution.
(All hail the originators)
Simply use this file instead of tnt_rates_nsw.sql
1. Updated to include NSW consignment sql file
2. Update admin so tax class can be set in admin as well as surcharge factor
3. Removed handling fee and combined with surcharge factor
4. Added in Fuel surcharge which can be updated in Admin
5. Updated formula to reflect above changes (TNT changed to up to 10 kgs without surcharge) to:
a) [z] * a * b (for less than or equal to 10Kgs)
b) [x * (y - 10) + z] * a * b (for greater than 10kgs)
x= charge per kilo over 15kg (changed in sql table)
y= total weight (I have deducted 15 kg from this because weight charge is only over 15kg) (total weight derived from product listing)
z= consignment charge (changed in sql table)
a= surcharge factor (eg. 1.08 = 8% surcharge)
b= fuel surcharge (eg. 1.1 = 10% fuel levy)
NB. tax is now added through tep_get_tax_rate built into oscommerce.
6. Updated Installation file
This is simply the same files with all references to Toll removed and replaced with TNT to avoid any possible confusion with Toll mod and because it looks better :)
Thanks Jay, for your contribution. It certainly saved me time!
I just thought, though, that it would be a good idea to mention here that it's important to change the rates in toll_rates.sql to suit the shipper's location.
For example, I had to get the rates for people shipping from Tasmania from TNT's website, and change them in that file. The toll_rates.sql file I attached here is suited to Tasmania.
Thanks again.
- Miles
I've now updated it so items under 15 kg can be used. Here only the consignment charge will be used and no cost per kilo.
BACKUP FIRST!
This mod for 2.2 CVS. Current as of July 2004.
It's a modified version of Lloyd Swadling's Toll courier rates. This mod is now for TNT Australia. Changes as follows:
1. Rewritten the entire postcode files to include all current postcodes AND changed all zones to TNT zones
2. Added in an initial consignment charge depending upon what zone goods are being sent to.
3. Changed shipping charge calculation to the following:
total shipping = {[x * (y - 15) + z]*1.10 * a}+ b
where:
x= charge per kilo over 15kg (changed in sql table)
y= total weight (I have deducted 15 kg from this because weight charge is only over 15kg) (total weight derived from product listing)
z= consignment charge (changed in sql table)
a= surchage factor (default 1.1)
b= handling fee (changed in oscommerce admin)
and the 1.10 bit is for GST
You don't need to download any other versions, this version will work by itself.
BUGS:
2. The only big bug I have is in the php file in catalogincludesmodulesshipping. On line 90 I have the equation to calculate the final shipping cost. However if the product weight is LESS than 15kg, you will receive an incorrect shipping calculation (try it yourself in the equation above). Unfortunately my programming skills aren't very good at all so if anyone knows the correct syntax for an IF statement would you be able to help out please? Basically to say the following:
IF product weight (y) is LESS than 15 then perform following equation:
{[z]*1.10 * a}+ b
IF product weight is 15 kg or MORE then perform following equation:
{[x * (y - 15) + z]*1.10 * a}+ b
Note: Contributions are used at own risk.