• Register
1 vote

Problem :

I am new to Google Maps. Currently I am trying to create the page that should be able to generate the dynamic numbers of Google Map. But my newly created webpage always shows me below message: 

“Geocode was not successful for the following reason: REQUEST_DENIED.”

I have already re confirmed that my Google API console and also re confirmed that my Geocoding API and Javascript API are also enabled. I am looking for the expert help on my Google Maps issue.

9 6 2
3,980 points

Please log in or register to answer this question.

1 Answer

1 vote

Solution :

I can surely help you in fixing your Google Maps related issue. So to begin fixing your issue your problem is related to loading your scripts as async so you should try to remove it..

You must try the jsfiddle with your API KEY only.

                    let mymapElement = 'map';
                    let myaddress = 'Australia';
                    mygeocoder = new google.maps.Geocoder();
  mygeocoder.geocode({ 'myaddress': myaddress }, function (results, status) {
    if (status == google.maps.GeocoderStatus.OK) {
      var mymapOptions = {
          zoom: 17,
          center: results[0].geometry.location,
          disableDefaultUI: true
      var mymap = new google.maps.Map(document.getElementById(mapElement), mymapOptions);
      var mymarker = new google.maps.Marker({
          map: map,
          position: results[0].geometry.location
    } else {
                    alert("Geocode was not successful for the following reason: " + status);
#map {
  width: 100%;
  height: 350px;
<script src="https://maps.googleapis.com/maps/api/js?key=APIKEY" type="text/javascript"></script><div id="map"></div>
I hope my above solution helps you.
5 4 2
17,150 points

Related questions

0 votes
1 answer 75 views
Problem : I am facing below error in place of maps on my website. &ldquo;This page didn't load google maps correctly. see the javascript console for technical details.&rdquo; Any solution on my error?
asked Jan 16, 2020 jwilliam 3.9k points
0 votes
1 answer 61 views
Problem : I am using two different third party programs those apparently use the Google Maps Javascript API. When they load the map, the world map is shown, but an Error message is displayed as below: you are using a browser that is not supported by the google maps javascript api
asked Oct 19, 2019 peterlaw 6.9k points
0 votes
1 answer 73 views
Problem: I am trying to auto-fill an address using the google mapsAPI in my application, but I keep getting the error "InvalidValueError: not an instance of HTMLInputElement". Below are the things I have tried Html input within a form. As you can see I tried the focus trick and it ... == undefined || place.geometry === null) { return; } }); }) } ) } Tried 4 different things, no luck this worked
asked Nov 4, 2020 sasha 8.4k points
0 votes
1 answer 15 views
Problem: Fairly new to the Google Maps Api. I've got an array of data that I want to cycle through and plot on a map. Seems fairly simple, but all the multi-marker tutorials I have found are quite complex. I am trying to add to this example the ability to assign each ... 'images/icon4.png' ], ['Maroubra Beach', -33.950198, 151.259302, 1,'images/icon5.png' ] ]; Thanks in advance for your answers!
asked Nov 10, 2020 Han Li 710 points
0 votes
1 answer 2K views
Problem : I am trying to develop the Android application using google map api v2 to show the Map in a Fragment. But when I run the application, I always faced the following error message appearing in my log every now and then. I ... .android.app C/GoogleCertificatesImpl: Fetched 154 Google release certificates 1921-2130/? V/GoogleSignatureVerifier: com.example.android.app signature not valid.
asked Dec 6, 2019 alecxe 7.5k points
0 votes
1 answer 2.1K views
Problem : I am facing following error message: DOMException: Failed to load because no supported source was found in video.play(); line. I have started getting this issue only after adding following code: video.setAttribute('crossorigin', 'anonymous'); I am trying to develop an app in the mobile so ... 0); setTimeout(loop, 1000 / 30); // drawing at 30fps } })(); }, 0); </script> </body> </html>
asked Nov 27, 2019 alecxe 7.5k points
0 votes
1 answer 80 views
0 votes
1 answer 11 views
Problem: form submission canceled because the form is not connected
asked Feb 18 charles mathews 3.8k points
0 votes
1 answer 439 views
Problem : I am unable to solve my link problem. Can anybody help on to this to link the CSS and JS File? I am facing below error : Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8080/RetailSmart/jsp/ ... .js Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8080/RetailSmart/jsp/Jquery/prettify.js
asked Jan 10, 2020 alecxe 7.5k points
0 votes
1 answer 5 views
Problem : this api project is not authorized to use this api.
asked Feb 18 Shovo210 2.4k points