VirtueMart

WooCommerce

Others

Docs

Support

Demo

Blog

About

Forum

We are currently unable to provide proper support!

We are very sorry to announce that we are currently very busy working on some huge, very time-consuming and time-sensitive projects, so currently we are unable to provide proper support in our forums! We hope that after the conclusion by the end of July we will be able to properly answer all open support requests.

Sorry for the inconvenience and thank you for your understanding!

Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC: Different Shipping rates by city with the same ZIP

Different Shipping rates by city with the same ZIP 19 Sep 2017 17:26 #1

  • VIPER975
  • VIPER975's Avatar Topic Author
  • Offline
  • Posts: 1
Hi,
I need to set different shipping rates for different cities. This is because we have different shipping rates in the same ZIP code for different cities.
Example 1:
ZIP: 04020
City: Ponza
Shipping rate: 15,50€

Example 2:
ZIP: 04020
City: Itri
Shipping rate: 5,50€

How can I fix it?
Thanks

Please Log in or Create an account to join the conversation.

Different Shipping rates by city with the same ZIP 21 Sep 2017 00:59 #2

Dear Viper975,
In addition to the ZIP variable, there is also the City variable available, which holds the user-entered city name:
ZIP==04020; City="Ponza"; Shipping=15.5
ZIP==04020; City="Itri"; Shipping=5.5

Note, however, that this relies on the customer entering the city correctly. If the customer makes any typo in the city, none of the rules will match. To handle this case, you can add a fall-through rule that displays a warning/error message to the customer:
ZIP==04020; City="Ponza"; Shipping=15.5
ZIP==04020; City="Itri"; Shipping=5.5
ZIP==04020; Warning="Unknown city: the 04020 postal code consists only of the two cities Ponza and Itri. Please enter either."; NoShipping

Best regards,
Reinhold

Please Log in or Create an account to join the conversation.

  • Page:
  • 1

VM - Shopping cart

 x 

Cart empty

Login Formular