Eric Koslow
Eric Koslow

Reputation: 2064

Where do you load the Google Maps API in a GWT project?

In my project.gwt.xml file I have

<script src="http://maps.google.com/maps?gwt=1&amp;file=api&amp;v=2&amp;sensor=false;key=MYKEY" />

But, when I load my page I get the google map gadget to come up, but with no map and an error message "Your page is missing the Google Maps API." Is there a different place I need to load the API?

Upvotes: 0

Views: 1890

Answers (2)

Eric Koslow
Eric Koslow

Reputation: 2064

Looks like I got it to work myself. I added to my project.html file:

<script src="http://maps.google.com/maps?file=api&v=2&key=MYKEY" type="text/javascript"></script>

And it started working. Probally not the best way of solving the problem, but it worked!

Upvotes: 3

Templar
Templar

Reputation: 5135

I would suggest that you use the Google Maps Library for GWT. You'll have a much easier time than if you try to get the standard Google Maps API working in your GWT project.

Upvotes: 0

Related Questions