搜索附近的 Google 个地点中的 JSON 个

Getting JSON of Google Places Nearby Search

我正在尝试获取附近搜索 Google 个地点 API 的结果 json。我收到此错误:"No Access-Control-Allow-Origin header is present on the requested resource."
我使用的代码是:

<html>
  <head>
    <title>Place searches</title>
    <script type="text/javascript" src="lib/jquery-2.1.1.min.js"></script>
    <script>
      
      var mJson = "http://maps.googleapis.com/maps/api/place/nearbysearch/json?location=-33.8670522,151.1957362&radius=500&types=food&name=cruise&key=AIzaSyCy639YCvWAzb3Sx0wkMzO5gxG-nHei4QU";
      $.getJSON(mJson,function(data){
        console.log(data);
      });

    </script>

  </head>
  <body>
    <h1>Google places test</h1>
  </body>
</html>
我什至在 jsonlint.com 网站上发布了 url,它给了我正确的 json,但我不明白为什么它在我的浏览器上不起作用

不要使用 Places web service api from javascript, use the Places Library

问题跟踪器中的相关问题(标记为"WorkingAsIntended"):