Post by yello » Thu Sep 29, 2016 10:44 pm

Just wondering how you guys are handling Geozones? Of course they need to be removed for at least all european countries.

When I do i.e. Geozones>Germany>Hessen>Disable (and all other German states). The Geozone drop down menu still appears, but has not 'State' options. It also doesn't appear on the address field.

This is not perfect, but OK. Only problem, there are some 1000 or so Zones that need to be removed. Manually.

I would probably simply set them with phpmyadmin, but before I do that I like to check if there is any other fast way.

In MySQL looks like you just set oc_zone > country_id 81 (Germany) > status from '1' to '0'

New member

Posts

Joined
Wed Dec 03, 2014 9:00 pm

Post by Pooleyy » Thu Sep 29, 2016 11:14 pm

Hi Yellow,

First why do you want to disable Geozones? What's your plan with shipping/tax?

Thanks
Sam

New member

Posts

Joined
Thu Oct 08, 2015 9:25 pm

Post by IP_CAM » Fri Sep 30, 2016 9:26 am

You may remove everything from your Database, not required, to run your Shop. By Example, if you remove all Countries, and all Zones related to those countries, as a result, you will have a FEW THOUSAND SURPLUS Data Lines less on your DB. In your ADMIN Section, and depending on how many FIELDS you have set to be visible in the Admin Section, you could BULK-Remove all large Portions of such Zones or Countries, with one single Click. But only those, not linked with ACTIVE Data, such as Users, Taxes defined, and so on, such would have to be NULLED before.
As a result of such, you will experience a remarkable general Increase in DB Performance as well.
---
Check here, how a registration form then would look, I shrinked a Test Shop, data-wise, to make it visible:
http://www.bigmax.ch/oc22/index.php?rou ... t/register
---
But you better NOT remove GEO-ZONE, as a GLOBAL Value, because it is linked into different sections and processes, and it could have severe effects, in some places, if no VALID Geo-Zone exists. But they can be DISABLED, by Default.
You could also define the ALL-Selection as beeing Standard, and shown accordingly, on i.E., the Reg-Field, as well, defined with the default TAX-Value to it.
--
You could even HIDE the ZONE Selections like Region/State from beeing visible on Screen, depending on requirements, in an easy way, I wrote about this, some time ago, around here somewhere...
--

Just to give you some Ideas on such !
Good Luck ;)
Ernie

My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.


User avatar
Legendary Member

Posts

Joined
Tue Mar 04, 2014 1:37 am
Location - Switzerland

Post by yello » Fri Sep 30, 2016 11:40 am

Pooleyy wrote:First why do you want to disable Geozones? What's your plan with shipping/tax?
Geozones are simply not required for many countries and buyers might feel strange to get ask for it. For example in Germany the 'State' will be never used in an address. That is different from i.e. USA were you must add TX or whatever.

When I ship to DE (or any EU country) the actual state doesn't make any difference in shipping cost or tax.

@IP_CAM
So far I tried to manually set a few Geozones to disable, and also tried setting the MySQL value to '0' for others.

I will try your method too. Afghanistan is a good starting point, they don't require states and I am unlikely to get many orders from there anyway (and I don't have to scroll for ages).

New member

Posts

Joined
Wed Dec 03, 2014 9:00 pm

Post by schiggi » Fri Sep 30, 2016 7:16 pm

Personally speaking, I made a small JS script to choose the first available state for each country. Then, I hide the state field in the checkout process. So you won't have a validation problem during checkout.

The only little downside is, that you won't have the correct states. Might be problem for you, depending, how sophistical you are making your sales analysis. I helped myself via the Google Maps api and passing the postcode/country to get the correct states.

New member

Posts

Joined
Tue May 13, 2014 4:23 am

Post by yello » Sat Oct 01, 2016 12:27 pm

schiggi wrote:Personally speaking, I made a small JS script to choose the first available state for each country. Then, I hide the state field in the checkout process. So you won't have a validation problem during checkout.
I don't really like that method. It means you have all the wrong Geo Zones in your DB, even though you never use them. For now my method is 'ok', where there is still the Geo Zone drop down menu, but the only option is 'none'.

For now it's good enough. I feel a bit there are more important problems soon....

This said, the developer should implement an easier Geo Zone removal page.

BTW, here is a great and official link for correct address formats for each and every country:

http://www.upu.int/en/activities/addres ... tries.html

New member

Posts

Joined
Wed Dec 03, 2014 9:00 pm

Post by schiggi » Sun Oct 02, 2016 10:33 pm

yello wrote:
schiggi wrote:Personally speaking, I made a small JS script to choose the first available state for each country. Then, I hide the state field in the checkout process. So you won't have a validation problem during checkout.
I don't really like that method. It means you have all the wrong Geo Zones in your DB, even though you never use them. For now my method is 'ok', where there is still the Geo Zone drop down menu, but the only option is 'none'.
Fair enough. That's why we implemented a generic zone called like the country to indicate, when the Google maps api lookup failed. So there won't be any wrong state written in the db.

But I absolutely agree, that it should be easy to make the state field not visible.

New member

Posts

Joined
Tue May 13, 2014 4:23 am
Who is online

Users browsing this forum: No registered users and 412 guests