Skip to content

Instantly share code, notes, and snippets.

@ChicagoMap
Created July 21, 2011 15:59
Show Gist options
  • Save ChicagoMap/1097510 to your computer and use it in GitHub Desktop.
Save ChicagoMap/1097510 to your computer and use it in GitHub Desktop.
Practice Fusion Table
<!DOCTYPE html>
<head>
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<style type="text/css">
html { height: 100% }
body { height: 100%; margin: 0px; padding: 0px }
#map_canvas { height: 100% }
</style>
<script type="text/javascript" src="http://maps.googleapis.com/maps/api/js?sensor=false"></script>
</head>
<body>
<div id="map_canvas"></div>
<script type="text/javascript">
var myLatlng = new google.maps.LatLng (41.85, -87.65);
var myOptions = {
zoom: 8,
center: myLatlng,
mapTypeId: google.maps.MapTypeId.ROADMAP
}
var map = new google.maps.Map(document.getElementById ("map_canvas"), myOptions) ;
var parks = new google.maps.KmlLayer ('http://data.cityofchicago.org/Government/KML-Parks/hmfy-xsta/rows.rss?accessType=DOWNLOAD');
parks.setMap(map);
var layer = new google.maps.FusionTablesLayer ('http://www.google.com/fusiontables/DataSource?snapid=S227081D-QX')
query: {
select: 'Geocodable address',
from: '1160343'
},
}),
layer.setMap(map);
</script>
</head>
<body onload="initialize()">
<div id="map_canvas"></div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment