Changes between Version 20 and Version 21 of BluePrintGISGeolocator


Ignore:
Timestamp:
11/17/10 04:07:48 (14 years ago)
Author:
mmatthews
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • BluePrintGISGeolocator

    v20 v21  
    1616Basic Google/Yahoo webservice calls are in {{{modules/s3gis.py}}}.
    1717
    18 These have been tied to the front-end [wiki:BluePrintGISLocationsHierarchy#LocationSelector Location Selector] in a basic form.  Using the service requires entering part of an address in the Street Address text area, and optionally including a country in the hierarchical control, then clicking the "Geocoder Search," link.  The geocoder service will be queried, and results will be displayed to the user in a popup.  The user can select an address from the list, and the selected address will be used to populate the Street Address and zipcode in that text area, as well as the latitude and longitude lines.  See below for a list of features that should be added to this functionality.
     18These have been tied to the front-end [wiki:BluePrintGISLocationsHierarchy#LocationSelector Location Selector] in a basic form.  Using the service requires entering part of an address in the Street Address text area, and optionally including a country in the hierarchical control, then clicking the "Geocoder Search," link.  The geocoder service will be queried, and results will be displayed to the user in a popup.  The user can select an address from the list, and the selected address will be used to populate the Street Address and zipcode in that text area, as well as the latitude and longitude lines.
    1919
    20 Unfortunately, there are inconsistent data returns from the Google service so it doesn't always work (the OK button does nothing).
     20At the moment this workflow means that when "Geocoder Search" link is clicked, the Google service is queried and the results are shown to the user.  Sometimes the Google results will only include latitude and longitude values that are useful, and will not include a "ThoroughfareName" (street address), or a "Postal code."  When no thoroughfare name is present, the user is alerted, but the latitude and longitude values are populated.  When a thoroughfare name is in the results, the user is alerted to a success.  When a postal code is present, that fact is included in the successful alert.
    2121
    2222!GeoNames support needs adding (there is some !GeoNames functionality in S3GIS or another example in jQueryUI !AutoComplete: http://jqueryui.com/demos/autocomplete/remote-jsonp.html).
     
    2424[http://wiki.openstreetmap.org/wiki/Nominatim Nominatim] support needs adding
    2525 * http://wiki.openstreetmap.org/wiki/Cdauth%E2%80%99s_map has a good search widget for this which could be incorporated
     26
     27== Notes ==
     28
     29There have been a avenues explored for this project that have proven to be deadends.  Great pains were taken in order to get the right information out of the geocode() controller's return, which, at the moment, happens to be raw returns from Google.  The problem with those efforts is that Yahoo returns a completely different data structure.  These obviously have to be standardized.
     30
     31It was originally thought that the 3rd party geopy python module would be useful to achieve this standardization, however there are two problems.  The geopy module still returns different data structures for both Google and Yahoo.  Additionally, for Google it only returns the long form of the address, and the lat/lon values, which are both trivial to parse out of the Google returns anyway (using "address" and "Point" as keys into the returned placemark).  Using this module proved to be a bit of a dead end.  It may be possible to use this module as a basis, however, with some slight modifications.
     32
    2633== API ==
    2734