Custom Countries Cannot Pay with PayPal
-
Hi,
I’m just wondering if you can add in an apply_filter call when setting the customer’s address.
The reason being is that WooCommerce has filters of its own to override the list of countries and of course in doing so you can add a country with its own code. In my case, my client wanted to add Northern Ireland in, because we’re based in Ireland. This is so they can offer different shipping methods (cheaper, at that) due to the fact that we’re on the same island, even if Northern Ireland is officially in the United Kingdom (GB). So, logistically speaking it makes sense. The country code I used was ND because, NI is already taken, but even so, PayPal only allows specific ISO 3166-1 alpha-2 country codes, so there’s no good option here.
Adding a filter would allow for a custom function to change ND to GB when the plugin sets the address object and then payment should process successfully. In the meantime I’ve just excluded PayPal from the available gateways when the shipping country is set to ND.
There could be several other scenarios like this for store owners around the world. Geography’s a funny thing! So I’m hoping you can add this feature as a filter or some sort of setting for an address override.
Thank you for your time.
- The topic ‘Custom Countries Cannot Pay with PayPal’ is closed to new replies.