Skip to content

Instantly share code, notes, and snippets.

Host *
Compression=yes
CompressionLevel=9
ControlMaster auto
ControlPath /tmp/%r@%h:%p
ServerAliveInterval 100
Host bastion
HostName bastion-21.network.hosting.acquia.com
User attilafekete
@Coornail
Coornail / serverReachable.js
Created September 17, 2011 10:33 — forked from louisremi/serverReachable.js
better navigation.onLine: serverReachable()
function serverReachable() {
// Cross-browser XHR creation
var request = new ( window.ActiveXObject || XMLHttpRequest )( "Microsoft.XMLHTTP" ),
status_code;
request.open(
// requesting the headers is faster, and just enough
"HEAD",
// append a random string to the current hostname,
// to make sure we're not hitting the cache