getting the url parameters or do I need to parse it myself?
getting the url parameters or do I need to parse it myself?
Code:// separating the GET parameters from the current URL var getParams = document.URL.split("?"); // transforming the GET parameters into a dictionnary var params = Ext.urlDecode(getParams[getParams.length - 1]);
Make sure that getParams.length is > 1, otherwise there is nothing to parse.
And since there can only be one "?" in a properly formed URL:
will do.Code:Ext.urlDecode(getParams[1]);