For the last 48 hours, the GMSReverseGeocoder on Google maps iOS SDK (latest version 2.7) returns results with missing addresses in areas with latitude and longitude that used to work properly. One example is:
GMSAddress {
coordinate: (37.915000, 23.730000)
lines: Alimos, Greece
subLocality: Alimos
locality: South Athens
administrativeArea: Decentralized Administration of Attica
country: Greece
}
Lines should contain the whole address but now it contains only the sublocality and the country. The issue is that it works properly for a couple of hours and then it returns to these kind of results and it never returns an error so I can use a fallback mechanism for reverse geocoding. (The results of this can be seen in popular apps like Lyft that rely on Google Maps iOS SDK for reverse geocoding).
Has anyone found a solution on how to overcome this? There is no api change in the geocoder in the latest updates.
PS. For the same lat/long, Google Maps Web Api and Android Api return fine results.
Related
HEREDeveloperSupport
Is there any method for AutoSuggestionRequest to get country specific result?
I am using the Native IOS SDK premium edition version 3.15,i need to show UK results only.
I am following the below code
let autoSuggestionRequest = NMAPlaces.sharedInstance()!.createAutoSuggestionRequest(location:geo,
partialTerm:text, resultType:getResultType())
autoSuggestionRequest?.languagePreference = languageLabel.text
I can't find this option in the 3.x Premium SDK (though I might also be missing it). As a workaround you can directly call the Autosuggest endpoint of the Search & Geocoding API. Using the "in" parameter and country code you can limit your results to a specific country.
Alternatively you can filter the results based on their country afterwards, though I understand that is less than convenient.
As per my R&D (posting date) and discuss with the HERE MAP support team on slack, there is no any method to find the Specific country address search result for example show UK results only. ( 3.x Premium SDK)
Now, I have created custom auto search bar using the POST API and it's working fine but it's showing the search address in your current location.
It seems to me several things I can do using google places web service api, cannot be done using google places ios sdk.
What I want to achieve is just getting the closest pizzeria and its information like address and telephone number. I don't use maps.
I don't see in the iOS sdk a method or class to search places close a specific location with several conditions (like type=restaurant and keyword=pizza).
However I can do that using the web service directly, without an sdk, but of course requires more code.
Am I right? Is that normal? I mean, that the iOS version has not the same functionality than the webservice, while I guess it is just a wrapper of the web service.
Web service sdk:
https://developers.google.com/places/webservice/search
iOS sdk:
https://developers.google.com/places/ios/
Thanks.
Unfortunately Places API for iOS doesn't support "condition" likes types or keywords.
You can however implement autocomplete.
The autocomplete service in the Google Places API for iOS returns
place predictions in response to a text-based location search query.
The request includes a textual search string and optional filter
criteria. You can use this service to provide autocomplete
functionality as the user types, by returning places such as
businesses, addresses and points of interest.
I am having issues finding any geolocation data on Mexico using bing's services. Example:
http://dev.virtualearth.net/REST/v1/Locations?countryRegion=MX&postalCode=66250&maxResults=1&key={my key}
Just gives me a central point for Mexico... In fact, I have tried 15-20 postal codes, not one has any specific location data for that postal code.
Am I doing something wrong? Thanks!
Bing Maps does not support postal codes in Mexico.
The app that I am currently working on has to do this kind of features.
1.User input "Address" and then there will be autocomplete (suggestion for that address)
2. After user hits search button . The MKMapkit has to bring user to that 'Address' and zoom region to that
I can do the #1 by using Google Autocomplete API and using this module TRAutocompleteView
Now ,I'm trying to figure to do #2 feature. I thought I can use Address result from google API to convert into lat,long by CLPlacemark but I tested the concept with this module which use CLPlacemark to convert address string
SPGooglePlacesAutocomplete
I found out that 20-30% of the address string can't be convert using CLPlacemark .It happes to be "Location not found" .And that happens mostly when you search in foreign language (I tried Thai language "
Are any other option for me implement these 2 features ? My app will be like YELP which has to search some result within specific region . Or can I use another way to do the address suggestion beside Google Autocomplete API ?
Changing MapKit to Google Map SDK can be one of the solution.But I want that to be last choice because it might be expensive if I exceed the daily limit
Thanks in advance
Just as a FYI, it is against the Google Terms of Service to use the Google Places Autocomplete with a non Google Map.
This is an obvious side effect of getting an address from Google and then asking Apple's API to turn those addresses into coordinates. Google will give you an address based on the data it has and the formatting style it wants, these will not always directly translate into Apple's data and format. If you want it to be properly reliable you need to stick with one set of services, Google or Apple, or a third party. It might be expensive if you exceed the daily limit but wouldn't that mean you're selling lots of copies of your app and such is the cost of doing business.
I'm using Google Maps V3 and it's not only having trouble getting exact geolocations, it's sometimes not finding the correct city (even missing by more than 50 miles in some cases).
The way I'm using google maps is in my Rails 3 app with the gem 'geocoder'. I feel pretty sure it's not the geocoder gem that's causing google maps to be off, I think I've had this problem in google maps V3 before.
My question: is there a better experience for determining the user's location? Should I use the browser's built in geolocation features? Or should I be using a combination of Google Maps Geolocation and the browser's geolocation functions?
I imagined a scenario where I could ask the user if the town was correct, and if not they could enter their town, then store their town in the database, but it seems like a poor user experience. I hope to make this a app on mobile devices in the future, where it wouldn't be much of a problem, but for now it's a web app.
Anybody else have a good system for dealing with apps that rely on a user's location? Thanks!
I ran into the same problem with Geocoder. For me it appeared to not interpret the address correctly in certain cases. If I sent it '250w 450n' as the street address I would get back the coords for *formatted_address":"250 E 450 S,*. If I sent '250 w 450 n' I got back the exact location I was looking for. Try checking the json response you get back from Geocoder, it will tell you "partial_match":true,"types":["street_address"]}} if it "guessed" at something, and you can check the returned *formatted_address* to see what it came up with.
you can use their website as a quick check on what response you would get for a given address string.