"alu" wrote
"Matt" wrote Hello,
I am pretty rusty with javascript and I am trying to make a webpage
that will basically act as a wrapper from one webpage to another. What
I mean by this is that I will hit this page like:
webpage.htm?Param1=... and I will take the passed params and post them
to another page. I have the post part working, but I was just
wondering how I can use just Javascript and read those values passed to
this webpage. Is this even possible?
Thanks for all of your time.
Matt
Yes, it's certainly possible.
The query string (the "?Param1=..." part of the url) is available via the
window.location.search property.
A google search on "parse query string javascript" will do the trick.
-alu
Just out of curiosity, has anyone else noticed that Win IE (~6.0.28) no
longer passes query strings from (Flash) ActionScript links on local files?
As for js, Javascript 1.3 documentation mentions "The search property...
applies to HTTP URLs only.", but it's never been an issue for local files on
any browser I've tested on in the past.
Bug, security issue, or correction?
-alu