Maximum distance field does not work
-
Hey,
The maximum distance field does not work if the delivery address is in the allowed postcode field e.g. 77000…77999.
Let me explain, I used your dbf_calculated_fee hook to calculate a fixed charge if the distance is between w and x and y and z.
function my_dbf_calculated_fee_callback( $calculatedFee, $kiloMeters, $divider, $price ) {
if($kiloMeters > 0 && $kiloMeters < 2.5) {
$calculatedFee = 8;
}
else {
$calculatedFee = 12;
}
return $calculatedFee;
}
add_filter( ‘dbf_calculated_fee’, ‘my_dbf_calculated_fee_callback’, 10, 4 );I have entered 8kms in the maximum field but if I enter an address that is 9kms away but has a postcode of 77000…77999 then the charges become free… and you can select the delivery option.
Please, have you had this case before?
Thank you in advance
- The topic ‘Maximum distance field does not work’ is closed to new replies.