Thanks I must've missed where it said they don't support calling it from the browser.
In that case, if I don't want to use the actual Google Places text input Autocomplete, I'll need to make each call to it via my web server then. I know 100,000 sounds like a lot for a quota limit but I wondered whether this may get used up quicker than expected if its an autocomplete field (a single user could account for 5-10 hits before they decide on a suggestion). I suppose even then though that still allows 10,000 users per day though. It must've been the quota for something else that I read that was based on IP address. Thanks for replying Barry. On Jun 30, 11:47 pm, Barry Hunter <[email protected]> wrote: > Google have said they dont support calling the Places API directly from > browser > > You either need to use the offical Javascript API. > > Or make calls from a server. > > Not sure why you are worried about using quota, as the Quota is based on > your API key not IP address. > > > > On Thu, Jun 30, 2011 at 9:54 PM, amnesia7 <[email protected]> wrote: > > If I use (obviously the input=value will be based on the content of > > the text field once I get it working but just static call for now)...: > > > $.getJSON("https://maps.googleapis.com/maps/api/place/autocomplete/ > > json? > > sensor=false&key=xxxxxx&location=50.741357,-1.963828&input=bourne", > > function(data) { > > alert(data.predictions[0].description); > > }); > > > ...it fails to load a response but if I manually navigate to the json > > web address, download the json file, upload it to my web server as a > > static file the following script will work fine (even though both > > contain the same content): > > > $.getJSON("json.js", function(data) { > > alert(data.predictions[0].description); > > }); > > > I assume this is because it is trying to cross domains. > > > Should there not be a json callback function available for use with > > this API because I couldn't find one on the documentation page? > > > The other option I can think might work is to download the json file > > using php with each request/keypress from my autocomplete but will > > this not mean that the quota limits are against my web server's ip > > address rather than the user's ip address if it were a javascript > > request? > > > Col > > > -- > > You received this message because you are subscribed to the Google Groups > > "Google Maps JavaScript API v3" group. > > To post to this group, send email to > > [email protected]. > > To unsubscribe from this group, send email to > > [email protected]. > > For more options, visit this group at > >http://groups.google.com/group/google-maps-js-api-v3?hl=en.- Hide quoted > >text - > > - Show quoted text - -- You received this message because you are subscribed to the Google Groups "Google Maps JavaScript API v3" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-maps-js-api-v3?hl=en.
