Skip to content

Instantly share code, notes, and snippets.

@spilliams
spilliams / leaflet_numbered_markers.css
Created May 23, 2012 23:55 — forked from comp615/leaflet_numbered_markers.css
Numbered Markers in Leaflet (JS Mapping)
.leaflet-marker-pane .leaflet-clickable {
position: absolute;
top: -55px; /* depends on icon graphic */
left: -17px; /* depends on icon graphic */
}
.leaflet-marker-pane .leaflet-clickable .number {
position: absolute;
top: 10px; /* depends on icon graphic */
width: 34px; /* depends on icon graphic */
text-align: center;
@spilliams
spilliams / Templater.js
Created May 23, 2012 02:06 — forked from bryfox/Templater.js
One variation on simple JS templating
/*global document */
(function (ctx) {
// Simple JavaScript Templating
// John Resig - http://ejohn.org/ - MIT Licensed
(function(){
var cache = {};
function tmpl(str, data){
// Figure out if we're getting a template, or if we need to
// load the template - and be sure to cache the result.