Can anyone advise me how to make a Google Map center properly within the frame of an Infragistics WebTab? Here's an example ...
http://www.peterklein.net/ (navigate: Photography > Places > NYC > Map)
showing how the map centers relative to the browser and not the WebTab. I found a couple of links discussing what I think are the same problem ...
http://forums.asp.net/t/1207085.aspx http://groups.google.com/group/Google-Maps-API/browse_thread/thread/2710b15f3d76ec2/67413d33e7fd0e74?tvc=2&q=asp.net
yet I confess I don't fully understand the javascript scenarios discussed. I'll post below the html from my Google Map page which is generated by an export from the program RoboGEO.
Thanks if anyone has advice about this.
Map page code ...
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>NYCMap</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="description" content="NYCMap - powered by Google Maps" />
<meta name="generator" content="RoboGEO v5.4" />
<script src="http://maps.google.com/maps?file=api&v=2&key=ABQIAAAAewLjz_kmTwF6agx5mipVJRSX99LV8rw0h8bwsLJz1iwYdESyThT3MJoRe6a83D6FfW7R20octwUtuw" type="text/javascript"></script>
<style type="text/css">
html, body, #map
{
width: 100%;
height: 100%;
}
body
margin-top: 0px;
margin-right: 0px;
margin-left: 0px;
margin-bottom: 0px;
font-family: Verdana, Arial, sans-serif;
font-weight: normal;
font-size: 11px;
#infotitle
text-align: center;
font-weight: bold;
padding-bottom: 10px;
font-size: 12px;
color: #CC0000;
#infodesc
float: left;
padding-right: 5px;
width: 180px;
#infoimg
</style>
</head>
<body onunload="GUnload()">
<div id="map"></div>
<script type="text/javascript">
//<![CDATA[
// check for compatibility
// call the info window opener for the given index
// open an info window
markers[i].openInfoWindowHtml(infoHtmls[i]);
// create the map
map.addControl(new GLargeMapControl());
map.addMapType(G_PHYSICAL_MAP);
map.addControl(new GOverviewMapControl());
// add the markers
request.open("GET", "map.xml", true);
if (request.readyState == 4) {
markerElementsLen = markerElements.length;
photos = new Array(markerElements.length);
infoHtmls = new Array(markerElements.length);
photos[i] = new GLatLng(parseFloat(markerElements[i].getAttribute("lat")), parseFloat(markerElements[i].getAttribute("lng")));
map.addOverlay(markers[i]);
document.getElementById("map").innerHTML = "Your web browser is not compatible with this website."
//]]>
</script>
</html>
I figured his out by reading this post ....
http://forums.infragistics.com/forums/p/7658/34234.aspx#34234