You need to get the URL parameters I'd suggest using a regular expression and/or jQuery, a quick example:
$.getUrlParameters = function(name, url) {
var theURL = url || window.location.href;
var results = new RegExp('[\\?&]' + name + '=([^]*)').exec(theURL);
if (!results) { return 0; }
return results[1] || 0;
}
See this similar topic:
How can I get query string values in JavaScript?
No comments:
Post a Comment