title: $http.get and $http.JSONP failed to get the google api response
body: <p>I tried to get api response for "<a href="http://maps.google.com/maps/api/geocode/json?address=Canada&amp;sensor=true&amp;region=USA" rel="nofollow">http://maps.google.com/maps/api/geocode/json?address=Canada&amp;sensor=true&amp;region=USA</a>" using angularjs $http .get method and $http.JSONP method. But it doesnt work properly it returns nothing.  When i tried this api via REST client and browser , it provides the JSON data with status code 200.</p>
  
  <p>Here is my code ...
  index.html</p>
  
  <pre><code>&lt;html ng-app="myApp"&gt;
  &lt;body ng-controller="MyCtrl"&gt;
  &lt;button ng-click="getlocation()"&gt;Get Location&lt;/button&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>app.js</p>
  
  <pre><code>var app = angular.module('myApp',[]);
  
  app.controller('MyCtrl', ['$scope','$http',function ($scope,$http) {
  
  
      $scope.getlocation=function(){
  
        $scope.method = 'JSONP';
        $http({method: $scope.method, url: "http://maps.google.com/maps/api/geocode/json?address=Canada&amp;sensor=true&amp;region=USA"}).
          success(function(data, status) {
  
            $scope.status = status;
            $scope.data = data;
            alert(JSON.stringify(data));
          }).
          error(function(data, status) {
            $scope.data = data || "Request failed";
            $scope.status = status;
            alert($scope.data+$scope.status);
        });
  
      }
  }]);
  </code></pre>
  
  <p>while run this code in browser it returns nothing. Throws error.
  Could you please help me to get out from this problem??</p>