I\'m guffawed here working on my first MVC 4 project with the Web Api variety.
In MVC 3 I could get a query string parameter like such:
var unicornName
If the linq is really that troublesome, just wrap the result of your GetQueryNameValuePairs()
in a dictionary:
var requestQuery =
list.ToDictionary((keyItem) => keyItem.Key, (valueItem) => valueItem.Value);
You can then get your string parameter just like you always have:
var unicornName = requestQuery["unicornName"];
I think this may be what you are looking for,
var queryValues = Request.RequestUri.ParseQueryString();
https://stackoverflow.com/a/11729619/6819