Skip to content

Instantly share code, notes, and snippets.

@naffiq
Created December 14, 2016 08:45
Show Gist options
  • Save naffiq/0aeb2e6eabf0134a95cf792445c018da to your computer and use it in GitHub Desktop.
Save naffiq/0aeb2e6eabf0134a95cf792445c018da to your computer and use it in GitHub Desktop.
URL query params (taken from http://stackoverflow.com/a/26744533/1319551)
params={};location.search.replace(/[?&]+([^=&]+)=([^&]*)/gi,function(s,k,v){params[k]=v})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment