Google Places API仅返回5个结果 [英] Google places API returning only 5 results

查看:110
本文介绍了Google Places API仅返回5个结果的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Google Places API,它仅返回前5个搜索结果.有什么方法可以增加计数.

I am using Google places API, It returns only top 5 search results. Is there any way to increase the count.

例如网址

我搜索了关键字"new"

I have searched for keyword "new"

推荐答案

来自文档:

JSON响应包含两个根元素:

A JSON response contains two root elements:

状态"包含有关请求的元数据.请参见下面的状态码.

"status" contains metadata on the request. See Status Codes below.

预测"包含一个位置数组,其中包含有关 地方. Places API最多返回5个结果.

"predictions" contains an array of places, with information about the place. The Places API returns up to 5 results.

来源: https://developers.google.com/places/web- service/autocomplete#place_autocomplete_responses

这篇关于Google Places API仅返回5个结果的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆