Is it possible to get data from an url with jquery
for example if you have www.test.com/index.html?id=1&name=boo
www.test.com/index.html?id=1&name=boo
how to get id and name?
A simple one if you know the url always has id and name
id
name
var url = "www.test.com/index.html?id=1&name=boo"; var id = /id=(\d+)/.exec(url)[1]; var name = /name=(\w+)/.exec(url)[1];