Created
May 4, 2015 21:51
-
-
Save michaelefisher/ad380c6193777499d18f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
window.Krux || ((Krux = function() { | |
Krux.q.push(arguments); | |
}).q = []); | |
(function() { | |
function retrieve(n) { | |
var m, k = 'kx' + n; | |
if (window.localStorage) { | |
return window.localStorage[k] || ""; | |
} else if (navigator.cookieEnabled) { | |
m = document.cookie.match(k + '=([^;]*)'); | |
return (m && unescape(m[1])) || ""; | |
} else { | |
return ''; | |
} | |
} | |
Krux.user = retrieve('user'); | |
Krux.segments = retrieve('segs') && retrieve('segs').split(',') || []; | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment