Another suggestion is to look at what the browser returns from
Window.Location()  It needs to exactly match the hostname or IP
address *and* port you passed when you registered the key.  If it
doesn't match, you'll get this error.  You can register more keys if
you need to, and use the AjaxKeyRepository class to pick one at
runtime.


http://code.google.com/p/gwt-google-apis/source/browse/trunk/ajaxloader/ajaxloader/src/com/google/gwt/ajaxloader/client/AjaxKeyRepository.java

On Mon, Nov 8, 2010 at 5:26 PM, ludwig <[email protected]> wrote:
> Thanks jumanor,
>
> How does one insert this script into the generated code given that GWT
> is generating this from:
>
> public final static String    MapKEY = "ABQIAAAA4-Uw-
> qkr1NiZhA-1JFJhmRQ8o_rih4NTeW_5Ph8tjVdhkL1UeRSDmMs4n1FDwaVtOct5xV-1HrZ7uw";
>
> public void onModuleLoad() {
>  Maps.loadMapsApi( MapKEY, "2", false, new Runnable() { public void
> run() { buildMap(); } } );
> }
>
> Thx - ludwig
>
> PS - I search for the dual insertion and found none.
>
> -------------------------------------
>
> On Nov 8, 6:10 am, jumanor <[email protected]> wrote:
>> I had the same problem with GWT Map, I solved the problem by inserting
>> this
>>
>> <script type="text/javascript" src="http://www.google.com/jsapi?
>> key=MapKey"></script>
>>
>> On 6 nov, 20:42, Rossko <[email protected]> wrote:
>>
>>
>>
>>
>>
>>
>>
>> > > I am using the GWT map interface and getting the "Site need a ..."
>> > > message. The map always load after the dialog is dismissed but would
>> > > like to get rid of this message.
>>
>> > That usually means an attempt to load the API twice, but only once
>> > with a key.
>>
>> > For help with using the API within GWT, go to the GWT 
>> > Grouphttp://groups.google.com/group/gwt-google-apis/
>> > (copied from this groups front page)
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Google Maps API V2" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to 
> [email protected].
> For more options, visit this group at 
> http://groups.google.com/group/google-maps-api?hl=en.
>
>



-- 
Eric Z. Ayers
Google Web Toolkit, Atlanta, GA USA

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps API V2" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-maps-api?hl=en.

Reply via email to