On Feb 18, 3:31 pm, Joe <[email protected]> wrote: > I've been asked to implement a delivery area service for an online ordering > application. Is there a way to query an address to see if it falls within > the boundaries for a delivery area for a given store ? Ideally I could do > this server-side, but I can't seem to find any good APIs for this, so I am > thinking of doing the geocoding using the client browser for the customer's > address and the is-within-radius calculation on the server side. It would > also be great to allow the customer to use a tool like this to define their > delivery radius per store. Any thoughts on how this could be achieved in > starting with this our-area tool?
I hope you are not implementing it in v2 of the Google Maps API (the topic of this group), that was officially deprecated May 19, 2010 and will no longer be supported after May 19, 2013. There are lots of examples of determining if an address is in a polygon (point in polygon analysis): a couple of v3 examples: using KML and geoxml3, a third party KML parser: http://www.geocodezip.com/geoxml3_test/v3_collection-map2e.html using FusionTablesLayer: http://www.geocodezip.com/v3_collection-map2e_FT.html -- Larry > > > > > > > > On Friday, 8 February 2013 12:28:01 UTC-5, Chris Bracher wrote: > > > I'm not sure. I think it had to do with the string that I pasted in, but > > it would seem that I did it incorrectly. > > > On Thursday, February 7, 2013 8:53:27 PM UTC-8, [email protected] wrote: > > >> On Feb 7, 7:28 pm, Chris Bracher <[email protected]> wrote: > >> > Beautiful, thank you!!!! > > >> I'm still curious, what did you do to get a map of Bogota, Columbia? > > >> -- Larry > > >> > Chris > > >> > On Thursday, February 7, 2013 6:53:03 PM UTC-8, [email protected]: > > >> > > On Feb 7, 6:25 pm, Chris Bracher <[email protected]> wrote: > >> > > > I'm trying to generate a full page version of the polygon I created > >> on > >> > > > Nirmal's Google map so that I can take a screen capture or print to > >> PDF. > > >> > > > Here's the code... > > >> > > > <iframe width="400" height="300" id="ourarea" src=" > >> > >http://www.nirmalpatel.com/ourarea/v.html?a=500westhamiltonave, > >> > > campbell > > >> ca&c=37.294045,-121.957726&f=true&p=yaobFh{wfV{_C~hAicAslCwsJzqHocFf}@bDl{B > >> `dAxlDj_@~y@el@|}DbhS~Lt{DmsE`kCeIktAuwSmzCrV&l=PIJIKGEIMJILJP"></iframe> > > >> > > > It displays correctly using his page and tool, but that's as far as > >> i > >> > > can > >> > > > get. > > >> > > - Delete the existing polygon on the map (by clicking on it, then > >> > > clicking the "Delete" button in the infowindow. > >> > > - Paste this string (the encoded polygon from the URL above), into > >> the > >> > > box under the "generate polygon from encoded" button (replacing the > >> > > example sting that is currently there): > >> > > yaobFh{wfV{_C~hAicAslCwsJzqHocFf}@bDl{B`dAxlDj_@~y@el@|} > >> > > DbhS~Lt{DmsE`kCeIktAuwSmzCrV > > >> > > - Click the "generate polygon from encoded" button (you should see > >> > > your polygon, I do) > >> > > - Click "Generate "Generate Map Text" for a JSON representation. > >> > > and/or > >> > > - Click "Generate KML" for a KML representation. > >> > > This is what I get (looks like a polygon in northern CA to me): > > >> > >http://www.geocodezip.com/geoxml3_test/v3_geoxml3_kmltest_linktoB.htm... > > >> > > This is the KML: > >> > > <?xml version="1.0" encoding="UTF-8" ?> > >> > > <kml xmlns="http://www.opengis.net/kml/2.2"> > >> > > <Document> > >> > > <Placemark> > >> > > <name><![CDATA[]]></name> > >> > > <description><![CDATA[]]></description> > >> > > <Polygon> > >> > > <extrude>1</extrude> > >> > > <altitudeMode>relativeToGround</altitudeMode> > >> > > <outerBoundaryIs> > >> > > <LinearRing> > >> > > <coordinates> > >> > > -121.86053000000001,37.27405,0 > >> > > -121.87237,37.29467,0 > >> > > -121.84971000000002,37.305600000000005,0 > >> > > -121.89881000000001,37.36524,0 > >> > > -121.90877,37.4018,0 > >> > > -121.92868000000001,37.400980000000004,0 > >> > > -121.95649000000002,37.38993,0 > >> > > -121.96593000000001,37.384750000000004,0 > >> > > -121.99648,37.391980000000004,0 > >> > > -121.99872,37.288120000000006,0 > >> > > -121.96473,37.25793,0 > >> > > -121.96310000000001,37.23552,0 > >> > > -121.85675,37.24918,0 > >> > > -121.86053000000001,37.27405,0 > >> > > </coordinates> > >> > > </LinearRing> > >> > > </outerBoundaryIs> > >> > > </Polygon> > >> > > </Placemark> > >> > > </Document> > >> > > </kml> > > >> > > > On Thursday, February 7, 2013 4:27:47 PM UTC-8, > >> [email protected]: > > >> > > > > On Feb 7, 12:42 pm, Chris Bracher <[email protected]> wrote: > >> > > > > > Which part of the code do you paste into geocodezip.com and > >> where > >> > > to > >> > > > > > generate the map? I'm in Northern California and it keeps > >> giving me > >> > > a > >> > > > > map > >> > > > > > in Bogota, Columbia... :) > > >> > > > > What are you trying to do? Do you have an encoded > >> polyline/polygon > >> > > > > from nirmal's our area tool? Or are you trying to export > >> geographic > >> > > > > information as KML? Something else? What is the input that is > >> giving > >> > > > > you a map in Bogota, Columbia? > > >> > > > > -- Larry > > >> > > > > > Thanks, Chris > > >> > > > > > On Wednesday, February 6, 2013 5:55:35 PM UTC-8, > >> > > [email protected]: > > >> > > > > > > On Feb 4, 8:23 am, "[email protected]" < > >> [email protected]> > >> > > > > > > wrote: > >> > > > > > > > On Feb 3, 5:11 pm, Ethan O'Hagan < > >> [email protected]> > >> > > > > wrote: > > >> > > > > > > > > Nirmal - super easy to use, took me about 40min to plot > >> the > >> > > > > delivery > >> > > > > > > > > territory I want. > >> > > > > > > > > How can I migrate / back this data up from your server > >> and > >> > > onto > >> > > > > Google > >> > > > > > > Maps > >> > > > > > > > > / Google Earth to give it to my point-of-sale company as > >> they > >> > > > > launch > >> > > > > > > my > >> > > > > > > > > online ordering? > > >> > > > > > > > It doesn't look like any data is stored on the server. The > >> URL > >> > > > > > > > generated: > >> > > > > > > > <iframe width="400" height="300" id="ourarea" src=" > > >>http://www.nirmalpatel.com/ourarea/v.html?a=Nebraska&c=41.492537,-99....}AqcbFfxv@_jfBff}@silAdfdDl`UzrlCmpp@z~eBgq@rrz`@~_dK?rfBstgK~<http://www.nirmalpatel.com/ourarea/v.html?a=Nebraska&c=41.492537,-99....> > >> <http://www.nirmalpatel.com/ourarea/v.html?a=Nebraska&c=41.492537,-99....> > > >> > > < > >>http://www.nirmalpatel.com/ourarea/v.html?a=Nebraska&c=41.492537,-99....> > > >> > > > > < > > >>http://www.nirmalpatel.com/ourarea/v.html?a=Nebraska&c=41.492537,-99....>daE~eBbwDulch@&l=PLLNPLMPOOPP"></iframe> > > >> > > > > > > > contains an encoded polyline which represents the data you > >> drew: > > >> > >http://www.geocodezip.com/v3_GenericMapBrowser.asp?filename=nirmapate... > > >> > > > > > > Here is a tool that will take an encoded polygon/line (the > >> output > >> > > of > >> > > > > > > the "our area" tool), put it on a map, can also export KML. > > >> > > > > > >http://www.geocodezip.com/blitz-gmap-editor/test4.html > > >> > > > > > > It also includes the Google Maps API v3 Drawing Manager for > >> > > drawing/ > >> > > > > > > editing polygons, polylines, circles, rectangles and markers > >> (it > >> > > is > >> > > > > > > built on the Google Maps API v3, not the deprecated Google > >> Maps > >> > > API > >> > > > > > > v2, the topic of this group). > > >> > > > > > > -- Larry > > >> > > > > > > > > Appreciate your help already, and thanks! > > >> > > > > > > > > Ethan in CA > > >> > > > > > > > > On Thursday, March 27, 2008 9:46:01 AM UTC-7, nirmal > >> wrote: > > >> > > > > > > > > >http://www.nirmalpatel.com/ourarea/ > > >> > > > > > > > > > I wrote this up one evening out of boredom because I > >> thought > >> > > it > >> > > > > > > might > >> > > > > > > > > > be useful to organizations/businesses that cover areas > >> that > >> > > > > don't > >> > > > > > > > > > follow along borders that are common knowledge. > > >> > > > > > > > > > Any comments are appreciated. -- You received this message because you are subscribed to the Google Groups "Google Maps API V2" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
