So based on the file that’s in your Github in ' boasaude / Assets / js / controllers / Mapacontroller.js',
I noticed on line 17
'google.maps.Event.addDomListener(window, 'load', initialize);'
After downloading the code I made the following change:
I switched to line 17 for a function call and it went like this:
"initialize();"
Note: Why doesn’t it work? window (window) is already loaded so addDomListener’s "initialize" did not start function.
Even so the map did not appear.... but I noticed that the contents inside the one that carries the map had changed...
I did a test by putting height and width and changing the code that was in index.html, thus staying:
<style>
html, body, #map-canvas {
/*height: 100%; Código antigo */
height: 600px; /* Novo */
width: 600px; /* Novo */
margin: 0px;
padding: 0px
}
</style>
And there... the map appeared.
I hope it helped.
Do you refer to the red item in the image on the right? It has no relation to Google maps.
– bfavaretto
@bfavaretto I put this image just to show that the files are loaded. That item in red is not the problem. My problem is loading the map.
– icejack
So, it’s difficult to help with this information. We would have to look at all your code in detail until we find the problem. You could isolate the problem and post a small example that reproduces what is occurring?
– bfavaretto
@bfavaretto What do you think, I will edit what I posted isolating just the problem reducing the codes and posting them here. Ok!
– icejack