Google maps is not working and for the life of me cannot figure out why. It works in a straight HTML file. At first I thought it may be the ASP.NET Menu Control conflicting, but now I have created this basic file and it still does not work. I call the Google Map code from the body onload, but then decided for testing to do it simple as below. Could someone please help?
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="map_no_master.aspx.cs" Inherits="AccountsRapport.map_no_master" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<div>
<div id="map_canvas" style="width: 300; height: 300;"></div>
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>
<script type="text/javascript">
var myLatlng = new google.maps.LatLng(51.372149, -0.457936);
var myOptions = {
zoom: 15,
center: myLatlng,
mapTypeId: google.maps.MapTypeId.ROADMAP
}
var map = new google.maps.Map(document.getElementById('map_canvas'), myOptions);
var marker = new google.maps.Marker({
position: myLatlng,
map: map,
title: 'Accounts Rapport'
});
</script>
</div>
</form>
</body>
</html>