title: Google Maps API Webservices
body: <p>I have been using the Google Maps Geocoding API Webservice for a few months now, and just recently it is giving me this error:</p>
  
  <pre><code>XMLHttpRequest cannot load http://maps.googleapis.com/maps/api/geocode/json?address=1600%2BAmphitheatr…in%2BView%2C%2BCA&amp;sensor=false. Origin is not allowed by Access-Control-Allow-Origin.
  </code></pre>
  
  <p>I am using the following code:</p>
  
  <pre><code>$.getJSON( "http://maps.googleapis.com/maps/api/geocode/json",
   { address : "1600+Amphitheatre+Parkway,+Mountain+View,+CA", sensor : "false" },
   function(data) {
    if (data.status == "OK") {
     alert("ok!");
    }
  });
  </code></pre>
  
  <p>According to
  <a href="https://developers.google.com/maps/documentation/geocoding/" rel="nofollow">https://developers.google.com/maps/documentation/geocoding/</a>
  I should be able to use the webservice api as above.</p>
  
  <p>I've also enabled the Google Maps v3 API and the Static Maps API in the Google API Console and set my domains to be allowed referrer domains but to no avail.</p>
  
  <p>Anyone know why this suddenly stopped working and how I can fix it? I'd like to be able to keep using the webservices as opposed to the Javascript API if possible.</p>