use*_*296 1 javascript json google-maps api-key
我正在使用该代码运行Geocoding,这完美无缺:$ url =' http ://maps.googleapis.com/maps/api/geocode/json?address= '.$地址.'&传感器=假';
问题是,它只运行几个地址(大约200),然后停止,所以我必须等待24小时再次开始地理编码.
所以我创建了一个API密钥,每天对2500个地址进行地理编码并添加如下:$ url = http://maps.googleapis.com/maps/api/geocode/json?&address=.$地址.&传感器=假键= MY_API_KEY;
现在的问题是,没有任何反应.没有地址进行地理编码.只有没有API密钥才适用于几个地址.我也尝试了不同的密钥,具有特定的引用,没有和引用 - 没有任何变化.不仅一个地址正在进行地理编码.
谢谢你的帮助!
查看使用密钥调用API时返回的错误消息:
http://maps.googleapis.com/maps/api/geocode/json?&address=New%20York,NY&sensor=false&key=my_api_key
{
"error_message" : "Requests to this API must be over SSL.",
"results" : [],
"status" : "REQUEST_DENIED"
}
Run Code Online (Sandbox Code Playgroud)
您需要使用https:协议.
https://maps.googleapis.com/maps/api/geocode/json?&address=New%20York,NY&sensor=false&key=my_api_key
{
"error_message" : "The provided API key is invalid.",
"results" : [],
"status" : "REQUEST_DENIED"
}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
2122 次 |
| 最近记录: |