Skip to content

Instantly share code, notes, and snippets.

View stevage's full-sized avatar
💭
🐘

Steve Bennett stevage

💭
🐘
View GitHub Profile
@stevage
stevage / index.html
Created November 7, 2015 12:25
Not just copyright
<!DOCTYPE html>
<html>
<head>
<style>
iframe { width: 100%; height: 700px; }
body { margin: 0; padding: 0; }
</style>
<body>
<iframe src="https://docs.google.com/document/d/1CYYXFW2mNaSCfVFOzjsz7EU-4KTz7uHeITvJMLWyVek/pub?embedded=true"></iframe>
</body>
{
// REQUIRED (DataPackage): a url-compatible short name ("slug") for the package
"name": "Victoria-ABS",
// REQUIRED (DataPackage): a human readable title for the package
"title": "Revenue, Expenses, Assets, Liabilities for Victoria (Australia) 2005-14",
"sources": [ {
"name": "ABS",
@stevage
stevage / carto layers
Created June 22, 2013 13:54
Proposed text for TileMill/carto's documentation on layer application.
The order in which objects are drawn depends on the following process. Each step in the process overrules steps with higher numbers.
1. Layers. "Higher" layers obscure "lower" ones.
2. Stylesheets. Stylesheets are applied from left to right.
3. Rules within a stylesheet. Rules are applied from top to bottom. This means two things:
a. objects defined by later rules will be drawn over those defined by later rules; and
b. attachments may be redefined by later rules.
4. Attachments (eg, `::glow { ... }`) within a rule are applied from top to bottom. (The order of different symbolizers within an attachment doesn't matter.)
5. Lastly, all else being equal, objects are drawn in the order in which they are found, such as in PostGIS.
@stevage
stevage / install-tilemill-latest.sh
Last active December 22, 2015 10:49 — forked from springmeyer/install-tilemill-latest.sh
Updated version to function more like proper bash scripts. (The 'sudo su postgres' stuff didn't work properly.)
#!/bin/bash
# First, clear out any old mapnik or node.js installs that might conflict
sudo apt-get purge libmapnik libmapnik-dev mapnik-utils nodejs
# Also clear out any old ppa's that might conflict
sudo rm /etc/apt/sources.list.d/*mapnik*
sudo rm /etc/apt/sources.list.d/*developmentseed*
sudo rm /etc/apt/sources.list.d/*chris-lea*
# add new ppa's
@stevage
stevage / index.html
Last active March 31, 2016 00:56 — forked from djtfmartin/index.html
LeafletJS and ALA occurrence layer
<!DOCTYPE html>
<html>
<head>
<title>LeafletJS and ALA occurrence layer</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet/v0.7.7/leaflet.css" />
<body>
<div id="map" style="height: 800px"></div>
<script src="http://cdn.leafletjs.com/leaflet/v0.7.7/leaflet.js"></script></head>
@stevage
stevage / patchfile
Created April 8, 2016 08:30
ECW SDK patch
--- Source/C/NCSUtil/NCSPrefsXML.cpp.ori 2016-04-08 08:28:13.365541000 +0000
+++ Source/C/NCSUtil/NCSPrefsXML.cpp 2016-04-08 08:28:58.665541000 +0000
@@ -32,7 +32,11 @@
} else {
char *pHomeDir = getenv("HOME");
if( pHomeDir ) {
+#ifdef NCS_BUILD_UNICODE
+ sUserPrefsFile.Format( NCS_T("%s%ls"), pHomeDir, NCS_T("/.erm/ncsuserprefs.xml") );
+#else
sUserPrefsFile.Format( NCS_T("%s%s"), pHomeDir, NCS_T("/.erm/ncsuserprefs.xml") );
@stevage
stevage / index.html
Created June 12, 2016 07:22
Railways
<!DOCTYPE HTML>
<html>
<head>
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet-0.5/leaflet.css" />
<!--[if lte IE 8]>
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet-0.5/leaflet.ie.css" />
<![endif]-->
<script src="http://cdn.leafletjs.com/leaflet-0.5/leaflet.js"></script>
<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
<style>
@stevage
stevage / index.html
Created June 12, 2016 07:24
Tableau test
<!DOCTYPE HTML>
<html>
<head>
<style>
.tableauPlaceholde { width: 50% !important; height: 811px; }
</style>
</head>
<body style="background:gray;">
This is...a test.
<!DOCTYPE html>
<html lang="en">
<body>
<iframe id="embedded-national-map" frameBorder="0" width="1200" height="600" src="http://nationalmap.gov.au/#clean"></iframe>
<script>
var xhr2 = new XMLHttpRequest();
xhr2.open('GET', 'polygon.geojson', true);
xhr2.onload = function() {
if (xhr2.status === 200) {
@stevage
stevage / index.html
Created January 2, 2017 09:42
Line-widths and data properties
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<title></title>
<meta name='viewport' content='initial-scale=1,maximum-scale=1,user-scalable=no' />
<link href='https://api.tiles.mapbox.com/mapbox-gl-js/v0.29.0/mapbox-gl.css' rel='stylesheet' />
<script src='https://api.tiles.mapbox.com/mapbox-gl-js/v0.29.0/mapbox-gl.js'></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/4.4.0/d3.min.js"></script>