Skip to content

Instantly share code, notes, and snippets.


Sindre Wimberger sindre

View GitHub Profile
View gist:6065403
// geo-location shim
// currentely only serves lat/long
// depends on jQuery
// doublecheck the ClientLocation results because it may returning null results
if (geolocation) return;
View gist:5764629
L.SingleTileWMSLayer = L.ImageOverlay.extend({
defaultWmsParams: {
service: 'WMS',
request: 'GetMap',
version: '1.1.1',
sindre / leaflet-side-by-side.html
Created Sep 24, 2012 — forked from andrewharvey/leaflet-side-by-side.html
Demo web app displaying two web maps side by side in sync with each other based on Leaflet
View leaflet-side-by-side.html
<html xmlns="">
This file is licenced CC0
<meta http-equiv="Content-type" content="text/html;charset=UTF-8" />
<title>Leaflet Maps Side by Side</title>
<link rel="stylesheet" href="/javascript/leaflet/leaflet.css" type="text/css" />
<!--[if lte IE 8]><link rel="stylesheet" href="/javascript/leaflet/" /><![endif]-->
<style type="text/css">
sindre / gist:3003712
Created Jun 27, 2012 — forked from madrobby/gist:2997187
The ultimate media query to rule them all ("all" being high DPI/"Retina" screens)
View gist:3003712
@media (-moz-min-device-pixel-ratio: 1.5), (-o-min-device-pixel-ratio: 3/2), (-webkit-min-device-pixel-ratio: 1.5), (min-device-pixel-ratio: 1.5), (min-resolution: 1.5dppx) {
/* "retina" styles */
View TileLayer.TileJSON.js
L.TileLayer.TileJSON = L.TileLayer.Canvas.extend({
options: {
debug: false
tileSize: 256,
initialize: function (options) {
L.Util.setOptions(this, options);
View mobile tags for your '<head>'
<!doctype html>
<!-- Helpful things to keep in your <head/>
// Shi Chuan,
<!-- consider using below meta tags if you want to disable format detection by default -->
<meta name="format-detection" content="telephone=no"/>
<meta name="format-detection" content="address=no"/>
<!-- consider using below link tag if the page is duplicate content of a desktop version -->
sindre / ipadlabels
Created Jun 21, 2011 — forked from anonymous/ipadlabels
iOS Label fix
View ipadlabels
var iPadLabels = function () {
function fix() {
var labels = document.getElementsByTagName('label'),
for (var i = 0; labels[i]; i++) {
if (labels[i].getAttribute('for')) {
labels[i].onclick = labelClick;
View mobile-meta-links.html
View anzeige.html
<!-- Zweiter Versuch by @yatil --->
<!-- Nun auch mit Sprachauszeichnung. --->
<!-- Dritter Versuch by @sindrewimberger--->
<!-- Nun auch mit microformat. --->
<article class="vcard">
<h1 class="note">Die führende <span lang="en">Social Media</span> Agentur Europas sucht:</h1>
sindre / gist:593379
Created Sep 23, 2010 — forked from kaelig/gist:458477
HTML Newsletter - Make Outlook 2007+ behave with line-heights
View gist:593379
// Make Outlook 2007+ behave with line-heights
element {