I need to get the a parameter passed via a querystring. I need to get the value of the parameter and then use it in some javascript.
In my specific example, I am using the "tabview" object and would like to set the "selected" tab by getting it from the querystring. The querystring would be something like this
.html?tab=3
So, I want to get the "tab" parameter and extract the value to preset the tab on form i am displaying..
Thanks..
I need to get the a parameter passed via a querystring. I need to get the value of the parameter and then use it in some javascript.
In my specific example, I am using the "tabview" object and would like to set the "selected" tab by getting it from the querystring. The querystring would be something like this
http://www.myserver./pagex.html?tab=3
So, I want to get the "tab" parameter and extract the value to preset the tab on form i am displaying..
Thanks..
Share Improve this question asked Mar 4, 2010 at 2:30 angryITguyangryITguy 9,5518 gold badges59 silver badges85 bronze badges1 Answer
Reset to default 8It's well hidden in the History module.
If you have a page at a url like:
http://my.site./foo.html?QUERY=bar&OTHER=stuff
Then you can get the value for QUERY using:
var string = YAHOO.util.History.getQueryStringParameter('QUERY'); //returns "bar"
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744866872a4598027.html
评论列表(0条)