简体   繁体   English

使用Google Places api搜索

[英]using google places api search

I am designing an app that displays nearby places, I am using the google places api search, the problem is the nearby search doesn't return places except when I set the radius to 20000m however radar search displays places even when I set the radius to 500m the but I can't use the radar search because the radar search doesn't return names of places. 我正在设计一个显示附近地点的应用程序,我正在使用google places api搜索,问题是附近的搜索不会返回地点,除非我将半径设置为20000m,但是即使将半径设置为20000m,雷达搜索也会显示地点500m,但是我不能使用雷达搜索,因为雷达搜索不会返回地点名称。 please help me. 请帮我。 thank you 谢谢

You can still use the radar search. 您仍然可以使用雷达搜索。 The radar search will return a place_id for each listing, and you can use the Places API to get more details about each place_id . 雷达搜索将为每个列表返回一个place_id ,您可以使用Places API来获取有关每个place_id更多详细信息。

For example: 例如:

https://maps.googleapis.com/maps/api/place/details/json?placeid=PLACE_ID_HERE&key=API_KEY_HERE https://maps.googleapis.com/maps/api/place/details/json?placeid=PLACE_ID_HERE&key=API_KEY_HERE

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM