You must setCenter() your map.
The first map on that page only gets centred when you successfully
geocode the empty string by calling showAdress(''). Geocoding the empty
string always fails, so you then call abc(), which creates a second map
and centres it at ("","") with this code:
var map = new GMap2(document.getElementById("map"));
var lat="";
var lon="";
var center = new GLatLng(lat, lon);
map.setCenter(center, 15);
geocoder = new GClientGeocoder();
var marker = new GMarker(center, {draggable: false});
Because this is a new GMap2 object, you lose things like the zoom
control that you placed on the first GMap2 object that was in the div.
So the user can't zoom out, and would have to drag the marker hundreds
of screenwidths at zoom 15 to the nearest land. Except that you've not
enabled dragging.
Also, you're probably seeing problems in MSIE due to invalid HTML that
MSIE can't cope with. Try running your code through a HTML validator and
fixing the tables and forms.
--
Mike Williams
http://econym.org.uk/gmap
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Maps API" 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
-~----------~----~----~----~------~----~------~--~---