Skip to content

Instantly share code, notes, and snippets.

@andrewxhill
Created January 23, 2015 12:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andrewxhill/ae73aa593d9a258f785a to your computer and use it in GitHub Desktop.
Save andrewxhill/ae73aa593d9a258f785a to your computer and use it in GitHub Desktop.
template for harvard workshop
<!DOCTYPE html>
<html>
<head>
<title>CartoDB Workshop | CartoDB.js</title>
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
<link rel="shortcut icon" href="http://cartodb.com/assets/favicon.ico" />
<style>
html, body, #map {
height: 100%;
padding: 0;
margin: 0;
}
#btn {
position: absolute;
top: 60px;
right: 20px;
padding: 0;
}
#btn ul {
padding: 0; margin: 0;
list-style-type: none;
}
#btn li {
border-bottom: 1px solid #999;
padding: 15px 30px;
font-family: "Helvetica", Arial;
font-size: 13px;
color: #444;
cursor: auto;
}
#btn li:hover {
background-color: #eee;
cursor: pointer;
}
#btn li.selected {
background-color: #fff;
}
</style>
<link rel="stylesheet" href="http://libs.cartocdn.com/cartodb.js/v3/themes/css/cartodb.css" />
<!--[if lte IE 8]>
<link rel="stylesheet" href="http://libs.cartocdn.com/cartodb.js/v3/themes/css/cartodb.ie.css" />
<![endif]-->
</head>
<body>
<div id="map"></div>
<div id="btn" class="cartodb-infobox">
<ul>
<li id="first" class="selected">Do Something</li>
</ul>
</div>
<!-- include cartodb.js library -->
<script src="http://libs.cartocdn.com/cartodb.js/v3/cartodb.js"></script>
<script>
function main() {
// Add your code here
}
// you could use $(window).load(main);
window.onload = main;
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment