HttpRequest and QueryString

Feb 13, 2009 at 1:22 PM
If you have GET request and only one parameter in query string the HttpHelper.ParseQueryString does not parse query string properly. If you have request /module/info?param=blahblah you will obtain QueryString, which have one item with name=String.Empty and Value="param=blahblah". I thing that there is a mistake in HttpHelper.ParseQueryString line 43.
I tried to change the source code and then the QueryString has been parsed correctly.

Old version (HttpHelper.cs line 43):
if (queryString.IndexOf("&") == -1 && !queryString.Contains("%3d") && !queryString.Contains("%3D"))

New version (HttpHelper.cs line 43):
if (queryString.IndexOf("=") == -1 &&  queryString.IndexOf("&") == -1 && !queryString.Contains("%3d") && !queryString.Contains("%3D"))

Feb 24, 2009 at 10:55 AM
Try agani with the latest revision