Automatically disabling map location on inaccurate addresses

This topic contains 3 replies, has 3 voices, and was last updated by  Paolo 5 years, 5 months ago.

  • Author
    Posts
  • #31837

    witnwisdumb
    Free User
    Post count: 1

    Hi all. Searched the threads quite a bit but couldn’t find anything exactly like this. Would really appreciate some help on this. I have a database of over 6000 places to import, and only some of them have the exact location.

    I understand that latitude and longitude are mandatory fields. But I do NOT want to use automated tools to detect lat/long based on address, because 90% of the time, the place gets marked inaccurately on the map (especially for addresses in India), and I don’t want users to be misled.

    If I just assign standard lat/long coordinates for all places with inaccurate addresses in a given city, is there at least a way to disable maps from being displayed for those places? (Automatically, and not manually by editing individual places one by one.) Please help. I just can NOT do the entire thing manually.

    Thanks in advance!

    PS: I have multicity enabled.

    #31856

    Guust
    Moderator
    Post count: 29970

    I doubt very much this is possible at all, but let’s ask Paolo.
    Maybe there is a possibility if you reserve a special category for them, and then filter the detail page for that category.

    #31857

    witnwisdumb
    Free User
    Post count: 1

    Thanks for the reply, Guust.

    Any solutions, Paolo?

    Also, just in case this issue does not have a solution, what is my next best alternative?

    #31923

    Paolo
    Site Admin
    Post count: 31205

    Hi,
    i don’t think there is an easy solution for this.

    You can disable the map in listing page per CPT, Price or category. I’ll let you decide what’s best.

    Here you can find the instructions to hide a tab for a particular CPT only. https://wpgeodirectory.com/support/topic/hide-tabs-in-custom-post-type-2/page/2/#post-25090

    and here how to modify that for price package instead of CPT.
    https://wpgeodirectory.com/support/topic/moving-places-between-different-cpts/#post-26121

    For category you’d have to change the conditional check to:

    if ( in_category( 'no address' )) { //funtion to rearrange tabs here }

    In that case you would have to use the category “no address”.

    One problem will remain, which is the map in the listing page for that category. I think in that case that you could use a conditional widget plugin and show the map for all categories except that one.

    Let us know how you went.

    Thx

Viewing 4 posts - 1 through 4 (of 4 total)

The topic ‘Automatically disabling map location on inaccurate addresses’ is closed to new replies, this may be for inactivity, please open a new topic if you have a similar question.