Possible Duplicate:
Adding a parameter to the URL with JavaScript
If I wanted to add 2 suppose name and id values to URL. How can I do that using JavaScript?
Suppose we have URL: http://localhost/demo/
, then how to add these 2 parameters.
Possible Duplicate:
Adding a parameter to the URL with JavaScript
If I wanted to add 2 suppose name and id values to URL. How can I do that using JavaScript?
Suppose we have URL: http://localhost/demo/
, then how to add these 2 parameters.
If you're trying to redirect to a location with javascript, try:
location.href="http://localhost/demo/?" + id + "=" + value + "&" + id2 + "=" + value2
If you just want to modify what's in the navigation bar
location.hash = id + "=" + value;
"http://localhost/demo/" + "?name=" + escape(name_var) + "&id=" + escape(id_var)