-
Exclude home country
How can I exclude the home country address from a customers displayed address details.
It is obviously unnecessary to show the country on an address label unless the order is being sent overseas. Have sorted this out before but can't remember how and thought it was just a matter of correctly setting the store and shipping details in Admin but doesn't seem to work this time.
Thanks
-
Re: Exclude home country
use php to detect if country name meets your home country, if yes, don't display it.
should be easy.
-
Re: Exclude home country
The address formats are held in the database table:
address_format
These are then linked to the table:
countries
if you need a different format from what the defaults are, but just for your own country, you could add another format and change the field:
address_format_id
in the table:
countries
to the field:
address_format_id
any existing Order in the table:
orders
and update the fields for the 3 address_format_id used for customer, delivery and billing ...
The reason to make a new address format for you country is that other countries could be using the current one, and those you may wish to keep in the original format ...
If you do not need to keep the original format for other countries, then you could customize the existing address_format ...
-
Re: Exclude home country
first time to know this, thanks Ajeh
-
Re: Exclude home country
Thanks, had a Eureka moment and in the short while it took for you two to post remembered how to do it - dived into phpmyadmin and sorted it.
Thanks again
-
Re: Exclude home country
Thanks for the update that this is now working for you as needed ... :smile:
What method did you use that worked best for you?