Alright, I need help with some regular expressions. I'm trying to get all the GET parameters within javascript in one fell swoop, but can't. I'm wondering if you can help me with this.
Now, this is the result.Code://location.search = "?Name=Bob&Time=401&PM=0"; location.search.match(/([0-9a-zA-Z]+(\=)[0-9a-zA-Z]+)+/g)
Is there a way to make the expression return something like this?Code:["Name=Bob", "Time=401", "PM=0"]
I tried adding more parentheses but it's not working.Code:["Name", "Bob", "Time", "401", "PM", "0"]




Reply With Quote