Have two zone requirements?

Permalink Browser Info Environment
Hey JohntheFish!

Quick question for you! It is hard to explain though. I've got a client who has a zone for the city of Cheney, but it's only within city limits (4 digit addresses). Is there a way to do this in the ZBS?

Just thought I'd ask!

Type: Discussion
Status: Archived
rainmaker
View Replies:
JohntheFish replied on at Permalink Reply
JohntheFish
There are a variety of ways you may be able to handle it, depending on just how the address is expressed.

Within the country match, you could use one or a combination of:

- Split them by zip code? I don't know the resolution of zip codes. In the UK a post code is accurate to just a few houses within cities, so it would be easy to do in the UK by post code.

- Using the 'whole address', a regular expression to match 4 digits and also the city name.

- Subsequent rules to supercede earlier mismatches with a later match. For example, add rules to then match other states, cities, zip codes etc outside the area you want and put them in other zones.

- Rules can be negative as well as positive.

The trick to remember is that an address matches the first country rule, then the last matching rule within that country. So you can use that to match the country and a close match for your city/4 digits, then design subsequent matches to supercede earlier unwanted matches.

Finally, if none of that is close enough, you could replace the class that provides the matching rules to add your own specific custom rule in php.

In amongst all my addon development plans, one of the things I would like to do in the future for ZBS is to make key areas like the address matching rules pluggable for easy extension. I just need to find the time to do it all :)
rainmaker replied on at Permalink Reply
rainmaker
Hey JohntheFish!

I had a feeling the postal code was the way to go. Prob is that the zip codes can be a little bit more fickle here. For the most part, it's pretty good but for the smaller cities, it can be difficult.

And dang this is such a powerful plugin. I get what it is about having time. :)

Thanks!

concrete5 Environment Information

Browser User-Agent String

Hide Post Content

This will replace the post content with the message: "Content has been removed by an Administrator"

Hide Content

Request Refund

You have not specified a license for this support ticket. You must have a valid license assigned to a support ticket to request a refund.