My page should show a single Google Map.
If I throw the code in a JSFiddle, it works fine.
All of my files are in the same directory. I tested in Chrome and Firefox, both don't show the map. So I think there must be something about the way I am calling for access to my JavaScript and CSS.
HTML
<html>
<head>
<link rel="stylesheet" type="text/css" href="bob.css">
<script src="https://maps.googleapis.com/maps/api/js?sensor=false"></script>
</head>
<body>
<h1>My Heading</h1>
<div id="map"></div>
<p>My paragraph.</p>
<script type="text/javascript" src="bob.js"></script>
</body>
</html>
bob.js
var mapOptions = {
center: new google.maps.LatLng(37.7831,-122.4039),
zoom: 12,
mapTypeId: google.maps.MapTypeId.ROADMAP
};
new google.maps.Map(document.getElementById('map'), mapOptions);
bob.css
html, body {
height: 100%;
margin: 0;
}
#map {
height: 100%;
margin: 0;
}
Console output
