FAQ Database Discussion Community


Google Places Details search System.err

java,android,google-places-api
I'm attempting to locate a restaurant by name using an AutoCompleteTextView which successfully obtains the places id. I've also checked the http request manually in my browser which responds with the correct information. When this code is executed, a system.err is shown in the LogCat console in Eclipse. My code...

Android Place Picker closes immediately after launch

android,google-places-api
I am developing an android application as part of a project, and am using Google places API to display places of interest based on location. I am using the PlacePicker Inentbuilder to accomplish this. However, when the app is run, the place picker launches and then closes immediately (about 1-2...

Getting name of google places API (Place Search) for my current location

android,google-places-api,reverse-geocoding,location-based-service
I am making an android app, in which I will use the name of current location to search its details over wikipedia. for e.g. If I am in Madame Tussauds, First I ll get the current location coordinates then after reverse geocoding, it's info will be searched over wikipedia and...

Google Places JS API: autocomplete search with setInterval on markers

google-maps-api-3,google-places-api
I have successfully implemented some code for returning results from the Places Search Box, but I would like to use setInterval so there is some delay in between dropping the markers on the map. I'm having some trouble with my attempt at it. Any help is much appreciated as I'm...

Place Picker Automatically close after launch

android,google-places-api,google-places
I want to show place picker so that user can choose location of his/her own choice. But place picker child activity automatically closes after launch. I've check the API key multiple times and other permissions, everything is correct. Here is all the code. Please help! task_location.setOnClickListener(new View.OnClickListener() { @Override public...

google places autocomplete api not working in android

android,google-places-api,typed-arrays
I am using Google Places Autocomplete API in my android application. But the app doesn't work . The logcat is filled with these warnings. There is this warning regarding TypedArray which I think is creating the problem.Can anyone explain what may be the issue.The logcat content is given below. 02-02...

Google place api does not search gym in usa

ios,iphone,ipad,google-places-api,google-places
Google Place api : I am using the google place api for searching the nearest gym around the user location.But when i using the London latitude and longitude it shows the results accurately but does not show the result for u.s.a. it does not show the results.I don't know what...

How to detect that you are in the building using some Google /Location API on Android

android,geolocation,google-places-api,android-wifi,android-location
I need to detect when I enter into building from the street. Now I use the next: if your device are connected to the wifi - you are into the building. I use WifiManager.NETWORK_STATE_CHANGED_ACTION for that. But this is not entirely accurate, because there are many free zone wi-fi, in...

Javascript Google Place API library not getting loaded dynamically

javascript,autocomplete,google-places-api
My javascript code var script = document.createElement('script'); script.src = 'https://maps.googleapis.com/maps/api/js?libraries=places'; script.type = 'text/javascript'; document.getElementsByTagName('head')[0].appendChild(script); script.onload = function(){ var autocomplete; autocomplete = new google.maps.places.Autocomplete( (document.getElementById('autocomplete')), { types: ['geocode'] }); I get this error Cannot read property 'Autocomplete' of undefined at HTMLScriptElement.script.onload (mabapamavo.js:18:40) The above same code...

Google Place API - No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access

javascript,jquery,ajax,google-maps,google-places-api
I am new in jQuery. I am using Google Place API. What I want to get suggestion of place for type helping. So, what I have done is- var Google_Places_API_KEY = "AIzaSyAK08OEC-B2kSyWfSdeCzdIkVnT44bcBwM"; //Get it from - https://code.google.com/apis/console/?noredirect#project:647731786600:access var language = "en"; //'en' for English, 'nl' for Nederland's Language var Auto_Complete_Link...

What format does the Google Places Photos API return the image in?

jquery,angularjs,image,google-places-api,google-photos
Have a look at this API: https://maps.googleapis.com/maps/api/place/photo?maxwidth=400&photoreference=CnRtAAAATLZNl354RwP_9UKbQ_5Psy40texXePv4oAlgP4qNEkdIrkyse7rPXYGd9D_Uj1rVsQdWT4oRz4QrYAJNpFX7rzqqMlZw2h2E2y5IKMUZ7ouD_SlcHxYq1yL4KbKUv3qtWgTK0A6QbGh87GB3sscrHRIQiG2RrmU_jF4tENr9wGS_YxoUSSDrYjWmrNfeEHSGSc3FyhNLlBU&key=AddYourOwnKeyHere When you invoke it using Postman, or in a browser, it returns an image which is rendered beautifully. Now, from inside an app, when I use $http or jQuery to call this API, what is returned is LOTS of...

Google Places nearbysearch from Android?

android,google-places-api
I'm having trouble figuring out how to call the Google Places API from Android. Specifically I'm looking at the nearbysearch call right now. This is the full URL as it is sent: (minus my API key) https://maps.googleapis.com/maps/api/place/nearbysearch/xml?location=49.7088,-124.9712&radius=3000&sensor=true&key=YourAPIKeyHere I'm getting this error returned: <error_message>This IP, site or mobile application is not...

Google Places API library use without map - javascript

javascript,google-maps,google-places-api
I need to get the closest establishments in 100m radius from specific coordinates. I found the Google Places API sample code, but I don't use a map in my application, since this results will be rendered in a list. Here is the API code: var map; var infowindow; function initialize()...

Google Places API for Android Error: Status{statusCode=NETWORK_ERROR, resolution=null}

android,google-places-api
I have created a project under google developer console and wanted to use Google Places API for Android. I have enabled the API and integrated into my android application as per the guidelines on Google developer website (https://developers.google.com/places/android/start). The API is giving this error and after hours (and days) of...

Google place API not working some time

ios,iphone,google-places-api,google-places
I am using the Google place API for nearest place around my location. But some times Google place API returns the error { "error_message" = "You have exceeded your daily request quota for this API."; "html_attributions" = ( ); results = ( ); status = "OVER_QUERY_LIMIT"; } I know that...

Set the current place on google place api

java,android,google-maps,google-play-services,google-places-api
I'm trying to search places (like restaurants or hotels) around a Latlng using google place api's. Is there any possibility to change the result of Places.PlaceDetectionApi getCurrentPlace(mGoogleApiClient, pf); and set other coordinate. My code is: mGoogleApiClient = new GoogleApiClient .Builder(this) .addApi(Places.GEO_DATA_API) .addApi(Places.PLACE_DETECTION_API) .addConnectionCallbacks(this) .addOnConnectionFailedListener(this) .build(); ArrayList<String> restrictToRestaurants = new ArrayList<>();...

How to plot Google placeid points on a map

google-maps,google-maps-api-3,google-places-api
So, tricky problem... I've put together a bunch of extra attributes to associate with food related places to create a bespoke version map of locations. I've generated this using Google places. I've only stored the placeid, as per terms of service, associating those I've chosen with the extra attributes I've...

Google Places API : Add Place Privacy

google-places-api
With Places API, it provides the ability to add new places. How much are we sure that Google does not use these custom added places for their own marketing and research purposes. What if you want to keep these new places private to your applications. The Add Place section does...

Google Place API - jQuery JSON Persing of received Data

javascript,jquery,json,jsonp,google-places-api
I am using Google Place API to get suggestions of nearest position. I have managed to get the data from the server. I have a response from the server like this- { "predictions" : [ { "description" : "Australia", "id" : "3ba963f8de67dc16df0a8de60e46418338a3181a", "matched_substrings" : [ { "length" : 1, "offset"...

Google Places API Place.TYPE_ADDRESS missing?

android,google-maps,autocomplete,google-places-api
Using Google Places API for Android, I'd like to know how to create an AutocompleteFilter of type address. Specifically I don't know what value(s) to use for the placeTypes parameter in the AutocompleteFilter.create method (see https://developer.android.com/reference/com/google/android/gms/location/places/AutocompleteFilter.html). According to documentation (https://developers.google.com/places/supported_types#table3), the supported types are: geocode instructs the Place Autocomplete service...

ANDROID PLACE_PICKER (builder.build(context)

android,google-maps,google-places-api
Basically I am trying to implement a PLACE_PICKER for Android and I am getting this confusing error here: int PLACE_PICKER_REQUEST = 1; PlacePicker.IntentBuilder builder = new PlacePicker.IntentBuilder(); Context context = getApplicationContext(); startActivityForResult(builder.build(context), PLACE_PICKER_REQUEST); The error is coming in line 4:" (builder.build(context), " and I have no idea why, I am...

Unable to get details for a place using Google Places API - “Cannot invoke 'lookUpPlaceID' ”

ios,swift,google-places-api
I'm trying to get details about a place using the Google Places API for iOS. When attempt to call the lookUpPlaceID function, receiving the following Swift compiler error: Cannot invoke 'lookUpPlaceID' with an argument list of type '(String, callback: (GMSPlace!, _) -> Void)' let placeID = "ChIJV4k8_9UodTERU5KXbkYpSYs" placesClient!.lookUpPlaceID(placeID, callback: {...

using enableAutoManage() in fragment

android,android-fragments,google-places-api
Is there another way to connect Google API client? I use auto complete places and I have to use this code some where in MYFRAGMENT mGoogleApiClient = new GoogleApiClient.Builder(MainActivity.this) .addApi(Places.GEO_DATA_API) .enableAutoManage(this, GOOGLE_API_CLIENT_ID, this) .addConnectionCallbacks(this).build(); My problem with enableAutoManage(this, GOOGLE_API_CLIENT_ID, this) .addConnectionCallbacks(this).build(); I can't deal with it because when I replace...

Requesting JSON from Google Maps gives me REQUEST_DENIED

java,android,json,google-maps,google-places-api
I am wondering why my request keeps getting denied. I'm pretty sure my API key is correct, I selected android in Google Console, gave it my sha1 with my project name and grabbed the API key and stuck it in my project. However, it still keeps giving me REQUEST_DENIED if...

Google Map with Local Churches, how to construct API call?

javascript,google-maps,google-places-api
Is there are way to retrieve a map from Google using the API so that it displays a list of local churches with churches with markers? I have the basic syntax, and I have a basic API account setup, but I am not how/if I can use the type field....

Google maps Autocomplete api not same as specifications

google-maps,autocomplete,google-places-api
I'm teasing google places API and I run into strange behavior at Autocomplete that I don't understand. This is how I'm using it: const AUTOCOMPLETE_OPTIONS = { types: ['address'], componentRestrictions: { country: 'cz' } }; this.inputPlaceElement = $('#search-around-input') this.inputPlaceSearchBox = new google.maps.places.Autocomplete(this.inputPlaceElement[0], AUTOCOMPLETE_OPTIONS); google.maps.event.addListener(this.inputPlaceSearchBox,'places_changed', () => { console.log('place change') })...

Unable to parse google places JSON response - org.json.JSONException

java,android,json,google-places-api
I am receiving a JSON response from Google places API which I am trying to parse. But I am getting org.json.JSONException. This is my JSON response. https://maps.googleapis.com/maps/api/place/details/json?placeid=ChIJbf6hrtZ2AjoRwUPd_nrhVjM&key=AIzaSyBWKQHS39-SYUNxEEAry1FxrMET2NwhqxE I am using the following code to retrieve the formatted address. try { Log.e("test-ttt", jsonResults.toString()); // Create a JSON object hierarchy from the...

Can you search for businesses near you matching a particular list of businesses using Google Places API?

android,ios,google-places-api
Say I have a list of businesses in a Google App Engine Datastore. Is it possible to use Google Maps Api to display for example the 10 closest businesses listed in the datastore to an Android or iOS device's GPS coordinates?...

Searching for a specific entity(a specific bank) using Google Places API

android,google-maps-android-api-2,google-places-api
I am working on this android application of finding specific banks(by their names) nearby using Google maps API and i am stuck since am not sure how to do that. I have created a custom list and a map fragment getting the current location.From the custom list is a list...

How do I retrieve place details from the Google Places JS API using a place ID?

javascript,google-maps,google-places-api
When using the Google Maps Places API you can create an Autocomplete element attached to a map in order to search their library. When you select a place you can call autocomplete.getPlace() to retrieve a JSON object describing the place. One field of this is the place_id, Google's unique reference....

Why Google Places API is not executing my request?

javascript,html,google-places-api
I'm trying to create a simple application where I insert an area of search, what to search and a radius of search. I can't understand why it's only working properly the second time I perform my query search, I know the problem is probably in my codeAddress() function: function codeAddress(){...

difference between (html) google maps search results and maps/places api calls (fewer results)

javascript,google-maps,google-maps-api-3,google-places-api
I want to get restaurants in German cities to embed and process in a web page. I identify those cities through lat/long and radius (for approximation). When doing an online search on google maps, I see 100s of results. google maps restaurant search duesseldorf My attempt at an implementation (mostly...

Unable to get photo_reference from place details api

ios,google-places-api
I am using google places api to get that place's photo but i am unable to locate "photo_reference" field in the returned JSON. Here is what i have done so far. NSString *urlString = [NSString stringWithFormat:@"https://maps.googleapis.com/maps/api/place/details/json?placeid=%@&key=%@",placeId,appKey]; NSURL *url = [NSURL URLWithString:urlString]; NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url]; [request setHTTPMethod:@"GET"]; [NSURLConnection sendAsynchronousRequest:request...

How to Change Font Size & Font-Family of Google Places Autocomplete?

javascript,html,css,google-maps-api-3,google-places-api
I'm currently trying to adjust the CSS attributes of the Google Places Autocomplete in the Javascript API. In this link here I can see that the CSS classes are listed by Google. And I tried to edit the CSS directly in the HTML file: <style> .pac-item-query { font-size: 12px; }...

Google API Quota on Google API place autocomplete

google-maps,google-api,python-requests,google-places-api
I working on an application I would like to use Google API place autocomplete. It looks like every Google API has a limited use of,2 500 requests per day, even though this special API isn't mentioned in the following page API Google Maps for Work. My question is : How...

Google Place API Limit - NOT usage limit

javascript,google-places-api
I've managed to get Google Places up and running, but there seems to be a limit on the number of country variables I can add. I'm basing my code on one of their samples: https://developers.google.com/maps/documentation/javascript/examples/places-autocomplete-hotelsearch But every time I try to add a country to the var countries section and...

places not found using google places api in iOS

ios,search,google-places-api
I am new in iOS. I am trying to show nearby places with selected types types - Bar, Cafe, ATM etc I have created project on developer console. enable API (google places api, google map sdk, direction api) I have created iOS api keys but Api key not working I...

Google Map APIs not working after adding bundle identifier - iOS

ios,bundle,google-places-api,identifier
I Google developer console I created an iOS key as below: I want to restrict this key to one app only, so I "Edit allowed iOS application" add my bundle Id to it. My bundle Id is easily found in General tab of my project target as following: I don't...

How do I create a new activity for each city?

android,google-maps,google-places-api
Forgive me for being new to android app building. My plan is to build an app that would take a city and open a new activity for it. The problem is I really don't know how to go about that. My plan would be very similar to how the app...

Auto Complete TextView not showing drop down after 1 character

android,google-places-api,autocompletetextview
I am using autocomplete textview to display places from google places api.I have also set the threshold value to 1 still if the user types a character the drop down dosent occur.It occurs when the user types the 2 character.I dont know why this is happening.Please do help me out...

Custom markers for google places

javascript,google-maps,google-places-api
I am using the code below to display custom markers on my page using the google places. var iconUrl; if(place.types[0] == 'lodging'){ iconUrl = 'custom-markers/hotel_marker.png'; } else { iconUrl = place.icon; } How can i change the code above so i can display custom markers from more than one category?...

Android studio can not resolve com.google.android.gms.location.places.AutocompleteFilter

android,android-studio,google-play-services,google-places-api
I am trying to implement a autocomplete places search following this article. http://www.truiton.com/2015/04/android-places-api-autocomplete-getplacebyid/ I have followed all steps, and also added proper dependencies in my build.gradle file. dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) compile 'com.android.support:appcompat-v7:21.0.3' compile 'com.google.android.gms:play-services:6.5.87' } Also here are the meta data section in my manifest. <meta-data...

Is it possible to filter the GMSPlacePicker based on place type/category

ios,google-maps,google-places-api
Using the new google places api for ios, is it possible to filter the results returned via GMSPlacePicker based on place type/category. For example, if I want to return all the gas_station types nearby. Basically, I'm looking for something like GMSAutocompleteFilter, but for GMSPlacePicker....

Recursive entry to executePendingTransactions on using GoogleApiClient in Fragment

android,android-fragments,google-places-api,google-api-client
I am trying to use Place Autocomplete API in my app. I have a main Activity. I have a Fragment which is a part of MainActivity. In OnViewCreated() on this Fragment. private void rebuildGoogleApiClient() { // When we build the GoogleApiClient we specify where connected and connection failed // callbacks...

How to use Android Places API AutocompleteFilter

android,google-maps,autocomplete,google-places-api
I am trying to implement the new Places API for android in my app and I cant seem to figure out how to set a filter to the request. Here is my code. LatLng southWest = new LatLng(85, -180); LatLng northEast = new LatLng(-85, 180); LatLngBounds bounds = new LatLngBounds(southWest,...

Getting error when using google place api

android,google-places-api
I have used google place api to get the places in auto complete textview.After researching i have made a application.But when i run the application i get the below error ERROR This IP, site or mobile application is not authorized to use this API key CODE public class GetPlaces extends...

Best datatype to store and retrieve a Google Place's place_id

ruby-on-rails,postgresql,google-places-api
I'm working on a Rails application that would store the place_id of a business provided by the Google Places API. Is there are a better way of saving the place_id in the database instead of saving it as a varchar / character varying datatype? I'm using Postgres as my back-end....

PlacePicker activity doesn't call `onActivityResult` when nothing is selected

java,android,google-maps,android-activity,google-places-api
Here is the code that i have tried but when the user doesn't select anything and just return back the activity doesn't call the onActivityResult() method I called the PlacePIcker as googleMap.setOnMapClickListener(new GoogleMap.OnMapClickListener() { @Override public void onMapClick(LatLng latLng) { try { googleMap.clear(); PlacePicker.IntentBuilder intentBuilder = new PlacePicker.IntentBuilder(); Intent intent...

Android Google places API GeoDataApi.getAutocompletePredictions() sorted by distance from actual location

android,google-places-api
Before that, I've used some REST Google places API for my autocomplete text view. And I remember that the results were somehow relevant to my actual location. Now, they added new simplier api with GeoDataApi.getAutocompletePredictions() method to get the first predictions. But I can't find any way to add some...

Places of Interest not showing in Android Google Maps

java,android,google-maps,android-manifest,google-places-api
So I am following a tutorial to find places of interest: LINK. I turn my Places API & Google Maps V2 ON in Google Console. I have my API Key and everything set correctly, because my map does comes up and my current location. But the places never show. I...

Google Places API returns INVALID_REQUEST (Android)

android,json,google-places-api,autocompletetextview,api-key
I'm using for the first time the Google Places API on Android, because I need an AutoCompleteTextView which suggests places when the user types on it. So, I've activated the Google Places API and I've created the API key, a browser key as some tutorial says. When i run the...

Retrieve lat/long data based on search term - Google Maps API

google-maps,google-places-api
Is it possible to retrieve a JSON object of lat/long coordinates using a query term such as "Tesco", from within the Google Maps API?

How to get postal code with using Google Places API?

javascript,json,google-maps,google-places-api
I use Google Places API to implement autocomplete. I noticed that Google Places API doesn't return zip codes for some addresses: URL: https://maps.googleapis.com/maps/api/place/autocomplete/json?input=3&types=address&language=en&key=MY_KEY One of predictions: description = "3rd Avenue, NY, United States"; id = b9ea1b2047021e7b8f4d1e2d2033b4baafcc8d21; "matched_substrings" = ( { length = 1; offset = 0; } ); "place_id" =...

GooglePlacesAutocompleteAdapter (Android Places API) returning results outside of boundary

autocomplete,google-places-api
It seems that the sample code from Google that demonstrates the Google Places API for Android is returning results from outside of the given boundary. (https://github.com/googlesamples/android-play-places/). Searching for 'hardware' shows most results from Sydney (the hardcoded boundary), but also (occasionally) shows results from as far away as other cities (including...