Skip to content

Instantly share code, notes, and snippets.

View stevenbey's full-sized avatar

Steven Bey stevenbey

View GitHub Profile
@stevenbey
stevenbey / QueryString.js
Created June 22, 2012 11:28
Add QueryString to your JavaScript location object.
(function() {
var querystring = {};
window.location.search.replace(
/([^?=&]+)(=([^&]*))?/g,
function($0, $1, $2, $3) { querystring[$1] = $3; });
window.location.querystring = querystring;
})();