Possible to enter street address and show the neighborhood

New home Forums Visitor Generated Markers Pre-sale questions Possible to enter street address and show the neighborhood

This topic contains 16 replies, has 2 voices, and was last updated by  intownrunner 3 days, 5 hours ago.

Viewing 15 posts - 1 through 15 (of 18 total)
  • Author
    Posts
  • #51592

    intownrunner
    Member

    We would like to have a visitor enter their street address and then learn which neighborhood they are located in.

    There are about 25 neighborhoods and I know all of the boundaries.

    Would WP Google Maps be able to accomplish this?

    Thanks! — Steven

    #51600

    Perry
    Moderator

    Hi Steven

    Thank you for getting in touch.

    We don’t support polygonal area search at the moment, sorry.

    Is there anything else I can help you with?

    Kind regards
    – Perry

    #51601

    Perry
    Moderator

    Hi Steven

    Thank you for getting in touch.

    We don’t support polygonal area searching at the moment. Sorry about that.

    Is there anything else I can help you with?

    Kind regards
    – Perry

    #51718

    intownrunner
    Member

    Thanks for the reply and info.

    Is it possible to use the store locator functionality and then combine it with a custom overlay?

    This way users could enter their address and see their marker appear on the map.
    The overlay would then show them which neighborhood they are located in.

    Then they will have the information they need.

    #51724

    Perry
    Moderator

    Hi Steven

    What kind of custom overlay would you be using?

    Kind regards
    – Perry

    #51893

    intownrunner
    Member

    Thanks for the reply.

    I think I have a proof of concept working here:
    https://choa.thepartnership.com/find-my-neighborhood/

    Using the paid version of the plugin
    Then using the store locator map
    Then added some polygons over the map.

    If you try entering the address of 1165 North Highland, Atlanta, GA then you will see which neighborhood you are located it.

    Then the user clicks on the neighborhood polygon, and the neighborhood title pops up.
    The neighborhood title is a link that takes them to a page where they can purchase items related to their neighborhood.

    Does this make sense?
    Can you think of any improvements?
    Even if they are paid customizations, we are open to ideas.
    We want to make the best user experience possible.

    Thanks! — Steven

    • This reply was modified 1 week, 6 days ago by  intownrunner. Reason: updated links
    #51909

    Perry
    Moderator

    Hi Steven

    Thank you for getting in touch!

    We visited your site and went through the steps you described here, everything looks great.

    If there are any specific customisations which you would like us to look into, please feel free to ask!

    Kind regards
    – Perry

    #51962

    intownrunner
    Member

    Thanks for the reply.

    Would it be possible to get the Polygon Marker title to display by default rather than having a user click on the polygon?

    Ideally, we just show the polygon title window of the neighborhood of the address entered but I think from an earlier reply, this functionality is not available.

    I think we would be good with all neighborhood polygons displaying as it would remove one click from the user experience.

    Also open to any improvements that you can think of.

    Thanks! — Steven

    #51964

    Perry
    Moderator

    Hi Steven

    If I understand correctly you would like all the polygon infowindows to start open?

    Kind regards
    – Perry

    #51980

    intownrunner
    Member

    Correct.

    Thanks!

    #51991

    Perry
    Moderator

    Hi Steven

    Please go to Maps -> Settings -> Advanced and in the Custom JS field please paste the following

    jQuery(function ($) {
    
    	$(window).on("load", function (event) {
    
    		if(!window.WPGMZA)
    			return;
    
    		for (var i in WPGM_Path_Polygon) {
    
    			var map = WPGMZA.maps[0].googleMap;
    			var polygon = WPGM_Path_Polygon;
    			var infoWindow = infoWindow_poly;
    			var bounds = new google.maps.LatLngBounds();
    			var data = wpgmaps_localize_polygon_settings[WPGMZA.maps[0].id];
    			var content = $("<a></a>")[0];
    			var center;
    
    			content.innerHTML = data.title;
    			$(content).attr("href", data.link);
    
    			polygon.getPath().forEach(function (element, index) {
    				bounds.extend(element)
    			});
    
    			center = bounds.getCenter();
    
    			infoWindow.open(map);
    			infoWindow.setContent(content);
    			infoWindow.setPosition(center);
    
    		}
    
    	});
    
    });

    We’ve tested that as working at our end, however if you could please confirm the same at you end after applying this, that would be great.

    Kind regards
    – Perry

    #52208

    intownrunner
    Member

    Thanks for the reply and info.

    I added the above JS code and the polygon titles are not displaying when the map first loads.

    Page to test

    URL

    Buy a Boo


    Scroll down a bit on the page

    Address to use
    Crestridge Drive Northeast, Atlanta, GA, USA

    Any thoughts?

    Happy to provide admin access if needed

    Also, I saw this error message in the back end, could it be related?

    WP Google Maps: We recommend allowing REST API requests to the wpgmza endpoints. One or more REST requests were blocked, some of the plugins features may not function for unauthenticated users. Last reported at 13:16 2019-07-18.

    Thanks!

    #52209

    Perry
    Moderator

    Hi there

    We need to tweak that custom code a little, if you are able to provide admin access, that would be great.

    Kind regards
    – Perry

    #52211

    intownrunner
    Member
    This reply has been marked as private.
    #52212

    Perry
    Moderator

    Hi Steven

    Thank you for that.

    We’ve made that change, please let us know if you’re happy with the result?

    Kind regards
    – Perry

Viewing 15 posts - 1 through 15 (of 18 total)

You must be logged in to reply to this topic.