Get URL parameters using Javascript


/ Published in: JavaScript
Save to your folder(s)

Usage:
Let's say we have an url: http://primera.vremenno.net?foo=yes&bar=no

var hash = getUrlVars();
alert(hash['foo']); // returns 'yes'
alert(hash['bar']); // returns 'no'

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.